Hello to all!
Any help with the following issue will be greately appreciated.
I am querying two tables in Access 2002 that are linked via file ODBC to a Pervasive 7.0 database. A range of invoice numbers is what I need to pull and the query works fine when my selection criteria in the invoice field reads:
Between "INV0099985" And "INV0099999"
But, since I need the range of invoices to be entered by a user, when I change the selection criteria to:
Between [From Invoice:] And [To Invoice:]
After being prompted for the two values, I get an error:
ODBC - Call Failed
FYI here are the two SQL statements:
Works:
SELECT OEINVD.INVNUMBER, OEINVD.ITEM, OEINVD.QTYSHIPPED, OEINVD.INVUNIT, OEINVH.BILNAME, OEINVH.SHIPVIA FROM OEINVD INNER JOIN OEINVH ON OEINVD.INVNUMBER = OEINVH.INVNUMBER WHERE (((OEINVD.INVNUMBER) Between "INV0099985" And "INV0099999"))
ORDER BY OEINVD.INVNUMBER;
Does not work:
SELECT OEINVD.INVNUMBER, OEINVD.ITEM, OEINVD.QTYSHIPPED, OEINVD.INVUNIT, OEINVH.BILNAME, OEINVH.SHIPVIA FROM OEINVD INNER JOIN OEINVH ON OEINVD.INVNUMBER = OEINVH.INVNUMBER WHERE (((OEINVD.INVNUMBER) Between [From Invoice:] And [To Invoice:]))
ORDER BY OEINVD.INVNUMBER;
I have tried limiting the size of the data being queried by first writing a query that pulls all invoices greater than INV0099000 (we are currently up to just over INV0100000) and then querying that query with the above selection criteria but received the same ODBC error. The query ODBC Timeouts are set to zero.
Thanks
Any help with the following issue will be greately appreciated.
I am querying two tables in Access 2002 that are linked via file ODBC to a Pervasive 7.0 database. A range of invoice numbers is what I need to pull and the query works fine when my selection criteria in the invoice field reads:
Between "INV0099985" And "INV0099999"
But, since I need the range of invoices to be entered by a user, when I change the selection criteria to:
Between [From Invoice:] And [To Invoice:]
After being prompted for the two values, I get an error:
ODBC - Call Failed
FYI here are the two SQL statements:
Works:
SELECT OEINVD.INVNUMBER, OEINVD.ITEM, OEINVD.QTYSHIPPED, OEINVD.INVUNIT, OEINVH.BILNAME, OEINVH.SHIPVIA FROM OEINVD INNER JOIN OEINVH ON OEINVD.INVNUMBER = OEINVH.INVNUMBER WHERE (((OEINVD.INVNUMBER) Between "INV0099985" And "INV0099999"))
ORDER BY OEINVD.INVNUMBER;
Does not work:
SELECT OEINVD.INVNUMBER, OEINVD.ITEM, OEINVD.QTYSHIPPED, OEINVD.INVUNIT, OEINVH.BILNAME, OEINVH.SHIPVIA FROM OEINVD INNER JOIN OEINVH ON OEINVD.INVNUMBER = OEINVH.INVNUMBER WHERE (((OEINVD.INVNUMBER) Between [From Invoice:] And [To Invoice:]))
ORDER BY OEINVD.INVNUMBER;
I have tried limiting the size of the data being queried by first writing a query that pulls all invoices greater than INV0099000 (we are currently up to just over INV0100000) and then querying that query with the above selection criteria but received the same ODBC error. The query ODBC Timeouts are set to zero.
Thanks