Hi, I ran the following code to do union a table with some manual values : proc sql;
SELECT DISTINCT id, sub_id FROM mytable
union all select 'A','A'
union all select 'B','B'
union all select 'C','C' ;
quit; However, I gets an error saying : ERROR 22-322: Syntax error, expecting one of the following: a quoted string, !, !!, &, *, **, +, ',', -, /, <, <=, <>, =, >, >=, ?,
AND, AS, BETWEEN, CONTAINS, EQ, EQT, FORMAT, FROM, GE, GET, GT, GTT, IN, INFORMAT, INTO, IS, LABEL, LE, LEN, LENGTH,
LET, LIKE, LT, LTT, NE, NET, NOT, NOTIN, OR, TRANSCODE, ^, ^=, |, ||, ~, ~=.
ERROR 76-322: Syntax error, statement will be ignored. Could you please let me know how I should change the code to perform well, as this same code is easily run in SQL Server. Thanks
... View more