MySQL Forums
Forum List  »  PHP

Join 2 tables and store in 3rd table
Posted by: Pablo Ghi
Date: April 25, 2017 08:10AM

Hello everyone

I've an issue:

I have following 2 tables

¦---bb_tickets---¦
¦ id ¦ owner ¦
¦----------------¦
¦ 111 ¦ 2 ¦
¦ 145 ¦ 2 ¦
¦ 152 ¦ 3 ¦
¦----------------¦


¦---bb_users-----¦
¦ id ¦ user ¦
¦--------------- ¦
¦ 1 ¦ Admin ¦
¦ 2 ¦ PG ¦
¦ 3 ¦ FS ¦
¦----------------¦


i'd like to export in the 3rd table following data:


¦----Result----¦
¦ id ¦ user ¦
¦--------------¦
¦ 111 ¦ PG ¦
¦ 145 ¦ PG ¦
¦--------------¦



Have you idea if I must use the JOIN, and if yes, how to?

Thanks in advance

PG

Options: ReplyQuote


Subject
Written By
Posted
Join 2 tables and store in 3rd table
April 25, 2017 08:10AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.