I have currently 2 tables in my database with the same columns.
The data inside is different, but I need to combine them into 1 table with a query.
I tried with joins but somehow I get that it overwrites the other one.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You don’t want to do a join… you want to do a UNION
Let’s say you created your first table like this:
And your second table (with the same fields) like this:
You want a UNION statement like this:
Of course, you could select specific fields rather than SELECT * if you just wanted that.