hello, I am struggling with syntax for my PROC SQL statement. I am pulling data from a very large database table from an ODBC link, and want to specify records based on the first two letters of a text field. PROC SQL; CONNECT TO ODBC (DSN='CFD' USER=sa PWD=Password); CREATE TABLE SRORD_DETAIL AS SELECT * FROM CONNECTION TO ODBC (select SRORD_DET_ID,SRORDER_ID,LINE_NUMBER, PROD_ID, PACKSIZE_ID, QTTY_ORDERED, COMMENT, CUSTOMER_KEY FROM SRORD_DETAIL where CUSTOMER_KEY CONTAINS ‘OR’ ); QUIT; I can't seem to make the last WHERE statement work for syntax, I get this error: ERROR: CLI describe error: [Microsoft][ODBC SQL Server Driver][SQL Server]Incorrect syntax near the keyword 'CONTAINS'. : [Microsoft][ODBC SQL Server Driver][SQL Server]Statement(s) could not be prepared. (example of a record I want to keep in the image attached.) help appreciated!
... View more