"SELECT tblInvoiceDtl.BOL#, tblCustomers.CustName, " & _
"tblInvoiceHdr.InvoiceNumber FROM tblInvoiceHdr LEFT JOIN tblCustomers ON " & _
"tblInvoiceHdr.BillToNumber = tblCustomers.CustNumber LEFT JOIN tblInvoiceDtl ON " & _
"tblInvoiceHdr.InvoiceNumber = tblInvoiceDtl.InvoiceNumber " & _
"WHERE tblInvoiceHdr.Posted Is Null ORDER BY tblInvoiceDtl.BOL#, tblInvoiceHdr.InvoiceNumber;"
Though I'm not 100% sure, I think the (#) is the culprit. I thought Access reserved that for Dates. Try removing that. However, if you actually named the field that way, I would really suggest anyway that you rename it something like BolNum or BolNo. Not a good practice to put symbols in field names, causes conflicts.
have a nice one,
Last edited by Bud; 01-28-05 at 03:57.
Reason: fix tags
I recreated the tables and query statement. My query statement looks like this:
SELECT tblInvoicedtl.[BOL#], tblCustomers.CustName, tblInvoiceHdr.InvoiceNumber FROM (tblInvoiceHdr LEFT JOIN tblCustomers ON tblInvoiceHdr.BillToNumber = tblCustomers.CustNumber) LEFT JOIN tblInvoicedtl ON tblInvoiceHdr.InvoiceNumber = tblInvoicedtl.InvoiceNumber WHERE (((tblInvoiceHdr.Posted) Is Null)) ORDER BY tblInvoicedtl.[BOL#], tblInvoiceHdr.InvoiceNumber;
NOTE: I took out all the & _ syntax. Copy the above statement as is to your SQL Select statement and see if it works. Seems like there's a problem with your " & _ uses.