Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- SELECT route_id
- FROM insert_route
- WHERE
- INSERT_ID IN ( 21 )
- AND route_id
- IN ( 48, 49, 44, 50, 55, 43, 51, 25, 24, 52, 47, 31, 53 )
- AND route_id NOT
- IN (
- SELECT route_id
- FROM insert_route
- WHERE INSERT_ID =12
- )
- GROUP BY route_id
- HAVING count( DISTINCT
- INSERT_ID ) =1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement