question regarding JOIN statements

Results 1 to 2 of 2

Thread: question regarding JOIN statements

  1. #1
    Join Date
    Dec 1969

    Default question regarding JOIN statements

    I&#039;ve been working on using JOIN statements the last few days and I&#039;ve been doing well and getting some code work, but I can&#039;t completely understand how it works.<BR><BR>In all my documentation they refer to LEFT & RIGHT tables when performing joins. How do I know which table is LEFT and the other RIGHT? What if I&#039;m working with 4 or more tables. Is there in specific direction tables run?<BR><BR>table 1 &#060;--(to the far left)--&#062; Table 2 &#060;---(left of Table 1, right of table 3) ---&#062; Table 3 &#060;---(left of table 1 & 2, to the right of table 4)---&#062; Table 4<BR><BR>Etc.. Thanks

  2. #2
    Join Date
    Dec 1969

    Default RE: question regarding JOIN statements

    If you have the join<BR><BR> a join b on ...<BR><BR>a is the left and b the right table. No problem. The result of a join is a table so when you have<BR><BR> a join b on ... join c on ...<BR><BR>which is the same as <BR><BR> (a join b on ... ) join c on ...<BR><BR><BR>then c is joined with the resulting table from (a join b on ...). So in this case it is the result of (a join b on ...) that is the left table and c that is the right table.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts