Dmytro
Dmytro

Reputation: 2237

INNER JOIN vs MultiSelect in PostgreSQL

Can somebody completely explain what is big difference in these two methods? Is there misunderstanding in database theory of programmers? Can somebody give a good article about the question or just say - what is a difference in these methods in PostgreSQL?

Upvotes: 1

Views: 302

Answers (2)

Diogo Biazus
Diogo Biazus

Reputation: 622

In the PostgreSQL documentation there is a related topic. Explicit joins can give you more control over the execution order of statements using the join_collapse_limit GUC. Take a look at this page.

There are also all the other already mentioned advantages in readability and maintainability.

Upvotes: 1

Did you mean SELECT * FROM table1, table2 vs SELECT * FROM table1 JOIN table2 ON condition?

PostgreSQL optimizer makes this queries run with the same speed, but JOIN is more transparent and usable. Also, you can use LEFT/RIGHT JOIN.

Upvotes: 2

Related Questions