Toad World® Forums

nth_value from seen as a syntax error

2nd max salary in sql
/* Formatted on 22/06/2017 13:07:39 (QP5 v5.312) */
SELECT DISTINCT NTH_VALUE (sal, 2 from last) over() from emp;
The formater doesn’t like my FROM LAST. Which is a valid syntax.
Toad 12.11.0.82

I can confirm that problem on Toad 12.10 x64 on 11.2.0.3 x64 client