[SQL] JOINing 2 row sets

Forum rules
No question in this forum please
For any question related to a topic, create a new thread in the relevant section.

[SQL] JOINing 2 row sets

Postby Villeroy » Fri Jan 18, 2019 8:49 pm

Original topic: viewtopic.php?f=13&t=96607&p=462482#p462482

What does the JOIN keyword do with 2 tables?
Why are there so many variants of JOIN in the literature on SQL? Well, many of them are equivalent to each other.
How is it related to the Cartesian Product of the 2 tables?
Is there any difference between the inner join and the selection from 2 tables where A.X=B.Y? Answer: Some old fashioned database engines work more efficiently with JOINs. In HSQL they are equivalent.
Attachments
JOIN_us_now.odb
(13.93 KiB) Downloaded 1 time
Last edited by Villeroy on Wed Sep 18, 2019 1:06 pm, edited 2 times in total.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04, no OpenOffice, LibreOffice 6.x
User avatar
Villeroy
Volunteer
 
Posts: 27112
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: [SQL] JOINing 2 row sets

Postby UnklDonald418 » Sat Jan 26, 2019 12:18 am

Thanks for the useful examples, but I did notice a problem. Most of your queries contain inline comments that are preceded by //. That works fine in the Direct SQL mode, but most visitors will attempt to run them in the default mode and the Base parser will raise a Syntax error. Apparently the parser only allows comments to be preceded by --.
If your problem has been solved, please edit this topic's initial post and add "[Solved]" to the beginning of the subject line
Apache OpenOffice 4.1.6 & LibreOffice 6.1.5.2 - Windows 10 Professional
UnklDonald418
Volunteer
 
Posts: 1213
Joined: Wed Jun 24, 2015 12:56 am
Location: Colorado, USA

Re: [SQL] JOINing 2 row sets

Postby Villeroy » Wed Sep 18, 2019 12:58 pm

Thank you for the hint. I made this with LibreOffice which ignores the comments. I did not know that Openoffice refuses to run queries with inline comments. So I replaced it with another version without inline comments and added the documentation to the readme form.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04, no OpenOffice, LibreOffice 6.x
User avatar
Villeroy
Volunteer
 
Posts: 27112
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany


Return to Base

Who is online

Users browsing this forum: No registered users and 1 guest