
Formatting a join puts each table and its matching condition on its own line, so you can check the relationship at a glance. It cannot tell you whether the join condition or the resulting rows are correct.
select u.name,o.total from users u join orders o on u.id=o.user_id where o.total>100
FROM users u, then JOIN orders o ON u.id = o.user_id, then WHERE o.total > 100, each on its own line.u.id = o.user_id matches your schema, and confirm row counts with representative test data.SELECT u.name, o.total FROM users u JOIN orders o ON u.id = o.user_id WHERE o.total > 100
Standard produces the same lines for this query. A missing or wrong join predicate can multiply or drop rows. With a LEFT JOIN, a WHERE filter on the right-hand table removes the unmatched rows the left join was meant to keep.
