MySQL Forums
Forum List  »  Newbie

Re: Collate three tables into one
Posted by: Chris Huchel
Date: December 07, 2017 04:20PM

Peter Brawley Wrote:
-------------------------------------------------------
> If three tables can be joined by primary keys, you
> can merge them rowwise with ...
>
> select t1,c1, t1.c2, ... t2.c1, ... , t3.c1, ...
> from t1
> join t2 on ...
> join t3 on ...

I'll try this.

>
> What problem do you solve by creating a physical
> table?

This list has to be reconciled once a month, and it is very difficult to check what has been received when the data is in three different tables. If everything were in one table, I could check it by just looking for NULL entries in a particular column, filtered by date.

Options: ReplyQuote


Subject
Written By
Posted
December 07, 2017 02:55PM
Re: Collate three tables into one
December 07, 2017 04:20PM


Sorry, only registered users may post in this forum.

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.