Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- select * from sportGroups
- where location = 'Sofia-Mladost 1';
- select * from students
- where id = 2;
- select * from sportGroups
- where location = 'Sofia-Mladost 1' or location = 'Sofia-Liylin 7';
- select * from sports
- order by name;
- select * from coaches
- where egn = '7509041245';
- select * from students
- where id >= 1 and id <= 3;
- select students.name, sports.name
- from students join sports
- on students.id in(
- select student_id
- from student_sport
- where student_sport.student_id = sports.id
- );
- select students.name, students.class, sportgroups.id
- from students join sportgroups
- on students.id in(
- select student_id
- from student_sport
- where student_sport.student_id = sportgroups.id
- )
- where sportgroups.dayOfWeek = 'Sunday';
- select coaches.name, sports.name
- from coaches join sports
- on coaches.id in(
- select coach_id
- from sportgroups
- where sportgroups.sport_id = sports.id
- )
- where sports.name = 'football';
Add Comment
Please, Sign In to add comment