Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- table: Communication
- communication_id int
- customer_id int
- created datetime
- SELECT *
- FROM Customer cu
- INNER JOIN Communication co ON cu.customer_id = co.customer_id
- LEFT JOIN File f ON f.communication_id = co.communication_id
- LEFT JOIN Message m ON m.communication_id = co.communication_id
- ORDER BY cu.customer_id, co.communication_id
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement