Re: SELECT FROM ALL TABLES

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Are the tables relational ? ie do they key each other ?
pete

Bruce Levick wrote:
Hi Guys,
Am having a little trouble with selecting a certain piece of data from all
tables and then displaying the results.

I have 5 tables (Concepts, Illustrations, ID, Photos, Misc). All tables have
a column named (itemMonth). Which is simply a month of the year (any month).
I am trying to display the results of a SELECT query where itemMonth =
'April'. But can't for the life of me get the results from all the tables to
display from one SELECT query.

So for example the display might look something like this.

Here are all the new works from April (Concepts, Illustrations, ID, Photos,
Misc)
Concepts 1
Concepts 2
Concepts 3
Illustraion 1
ID 1
Photos 1
Misc 1
Misc 2


There could be any number of results from either of the tables. Obviously only after results where itemMonth = 'April'.

I have tried many combinations to get this to work. I don't think the
solution is to produce a select query for each table, that seems a bit code
heavy.

Sorry if I am missing something obvious....am a little tired.

Bruce






--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux