I've got a demo app, using php with an Access/Jet backend. I've got these (simplified) tables:
People
------
ID
BankID // foreign key in Banks
Name
Address
Banks
--------
ID
Name
Address
I'm doing a join:
SELECT * FROM People LEFT JOIN on People.BankID = Banks.ID
What's the best way to avoid name clashes? This works:
SELECT People.*,
Banks.ID as BankID,
Banks.Name as BankName,
Banks.Address as BankAddress
FROM People LEFT JOIN on People.BankID = Banks.ID
but it gets awful wordy when you have more than a few columns. Is there any way to say "prefix all of the columns in the Banks table with 'Bank'"?