Guest Jeff_A Posted July 6, 2006 Share Posted July 6, 2006 I have a recordset that has mutliple tablesExample :SELECT Customers.customerID, Invoices.customerID,Invoices.invoiceID, Customers.Name, Invoice.NumberFROM customersINNER JOIN invheader ON customers.customerid = invheader.customerIDI want to know, for each field the recordset returns, the name of the table where the field comes from......For example(request above), for the first field, it would tell me "Customers", for the second field, it would tell me "Invoices", for the third field, it would tell me also "Invoices" and for the fourth field, it would tell me "Customers", and so forth...I want this because the request that I have to deal with is dynamic...I hope you understant my post... Link to comment Share on other sites More sharing options...
justsomeguy Posted July 6, 2006 Share Posted July 6, 2006 You can always rename the fields to make them unique:SELECT Customers.customerID as c_custid, Invoices.customerID as i_custid, Invoices.invoiceID as i_iid,etc Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now