I have one table for users (userid is the pk) and a second table for items (itemid is the pk) I need to have those two tables into one table, how could I do that in phpmyadmin?
2
you cna use left join lateral :
left join lateral
SELECT * FROM USERS LEFT JOIN LATERAL ( select * from ITEMS) ITEMS ON 1 = 1 WHERE userid = 1
You seem to want a cross join:
cross join
select u.*, i.* from users u cross join items i where u.userid = 1;
Click here to cancel reply.
2
Answers
you cna use
left join lateral
:You seem to want a
cross join
: