Re: Alias *all* columns in a joined table?

2004-02-12 Thread Isaac Reuben
On Thu, 12 Feb 2004, Martijn Tonies wrote: > > SELECT > > person.*,place.* as home_* > > FROM > > person,place > > WHERE > > person.home_id = place.id > > AND > > name = 'Joe' > > What if more of your tables have a column "name"? then: person.*,place.* as home_*,thing.* as thing_* (etc...)

Alias *all* columns in a joined table?

2004-02-12 Thread Isaac Reuben
Say I have two tables, and they have several column names that are the same in both tables. I know I can manually alias the column names so that they don't overlap, but is there a way to prefix *all* of the columns of one table so that I can be sure the names don't overlap? So if I have these two