proc sql; connect to oracle (DEFER=XXX PATH=XXXX AUTHDOMAIN="XXXXXXXX" ); create table temp as select * from connection to ORACLE ( select at_date, shop, datepart(at_date) as date from ABC.GYGYGYG where datepart(at_date)=intnx('month',today(),-1,'e') /*want to get last date of last month*/ ); log: ERROR: ORACLE prepare error: ORA-00923: FROM keyword not found where expected. SQL Statement: select at_date,shop,datepart(at_date) as date from ABC.GYGYGYG where datepart(at_date)=intnx('month',today(),-1,'e')
... View more