Jump to content

Join.


Demonic

Recommended Posts

t1 is just a short name label for table1.
You can still use the original table1 name.

SELECT *
FROM table1
JOIN table2
ON table1.id = table2.id
ORDER BY table2.id


same thing.

Another way to join is:
SELECT * FROM table1, table2
WHERE table1.id = table2.id
ORDER BY table2.id

However, the first method is better since there's more things with you can do using  a JOIN clause.
Link to comment
https://forums.phpfreaks.com/topic/22444-join/#findComment-100631
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.