and thanks in advance for any help. I'm using Microsoft Query to interrogate Sage 50 tables. I'm trying to create a user defined field containing only the first digit of a customer account reference. I have been able to achieve this result when interrogating SAP tables, by using the Left or Mid functions. When I try exactly the same method with Sage, I get the error "column not found"
The SQL is as follows:
SELECT INVOICE.ACCOUNT_REF, LEFT(INVOICE.ACCOUNT_REF,1)
FROM INVOICE INVOICE
WHERE (INVOICE.ACCOUNT_REF Like "CHA002")
I'd expect the result of this to be "C" but I get
Column Not Found
Please help! I also will need to do similar to isolate the year from a date field - currently I get the same error here as well :-(
Please note that you need the % character for the like operator: