Performance comparison between different inner join syntax methods

I’ve been using SQL databases for some time now, and I’ve noticed there are two main ways to write inner joins. I’m curious if one method is faster or more efficient than the other.

The first method utilizes the JOIN syntax:

SELECT c.name, o.amount 
FROM customers c 
INNER JOIN orders o 
ON c.customer_id = o.customer_id;

The second method employs the traditional comma-separated table syntax:

SELECT c.name, o.amount
FROM customers c, orders o
WHERE c.customer_id = o.customer_id;

Both queries appear to yield the same results, but I am eager to know if one approach is better in terms of performance or if there are other benefits to opting for one method over the other.

interesting question! have you tested this on your actual database tho? what size tables are you working with? theory doesn’t always match reality - especially with different db engines and indexing. what’s your specific use case?

Performance-wise, modern database engines create identical execution plans for both syntaxes, so there’s no speed difference. But explicit JOINs have real advantages. The comma-separated approach gets messy fast with complex queries or outer joins - your WHERE clause turns into a nightmare mixing join conditions with filters. I’ve seen forgotten join conditions in WHERE clauses accidentally create Cartesian products that killed performance. Explicit JOINs make queries way more readable and prevent these errors by keeping join logic separate from filtering. Most database pros stick with JOIN syntax because it’s easier to maintain.

both methods work fine, but honestly, the comma syntax is kinda old-school. explicit joins are way cleaner and make it easier to read and review your code. just keep it simple, right?