Jump to content

Union problems


rockinaway

Recommended Posts

I have two queries joined together with a UNION. ALL the columns that are returned have the same name except 1 field in each table. In the first table the column is called 'football_id' while in the second column it is 'cricket_id'.

 

The query is running fine, but I just wanted to know how I can differentiate between the results that are returned as to see whether they are from the first table (where football_id is present) or the second table (where cricket_id is present). It isn't as simple as using an isset() is it?

Link to comment
https://forums.phpfreaks.com/topic/256677-union-problems/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.