MikeMcKeown
Programmer
I'm getting an SQL -120 error on this bit of SQL
-120 A WHERE CLAUSE, SET CLAUSE, VALUES CLAUSE, OR A SET ASSIGNMENT STATEMENT INCLUDES A COLUMN FUNCTION
EXEC SQL
SELECT ASU_NEW_NET_RATE
INTO :SMM03-ASU-NEW-NET-RATE
FROM SMM03 A
WHERE A.EFFECTIVE_DATE = MAX(A.EFFECTIVE_DATE)
END-EXEC
I just want to select the most recent row from the table.
Any help, much appreciated
Thanks in advance,
-120 A WHERE CLAUSE, SET CLAUSE, VALUES CLAUSE, OR A SET ASSIGNMENT STATEMENT INCLUDES A COLUMN FUNCTION
EXEC SQL
SELECT ASU_NEW_NET_RATE
INTO :SMM03-ASU-NEW-NET-RATE
FROM SMM03 A
WHERE A.EFFECTIVE_DATE = MAX(A.EFFECTIVE_DATE)
END-EXEC
I just want to select the most recent row from the table.
Any help, much appreciated
Thanks in advance,