获取 table 查询中插入的最后数据
get the last data inserted in table query
我想获取 5 分钟前插入的具有特定状态的最后数据,但我得到 SQLException expected "., (, [, ::, *, /, %, +, -, ||, ~, !~, NOT, LIKE, REGEXP, IS, IN, BETWEEN, AND, OR, ,, )";
,这里是查询:
SELECT *
FROM Table
WHERE (CREATE_DATE >(systimestamp - (interval '5' minute)) )AND STATUS='in progress';
所以答案是:
CREATE_DATE > DateADD(mi, -5, Current_TimeStamp)
我想获取 5 分钟前插入的具有特定状态的最后数据,但我得到 SQLException expected "., (, [, ::, *, /, %, +, -, ||, ~, !~, NOT, LIKE, REGEXP, IS, IN, BETWEEN, AND, OR, ,, )";
,这里是查询:
SELECT *
FROM Table
WHERE (CREATE_DATE >(systimestamp - (interval '5' minute)) )AND STATUS='in progress';
所以答案是:
CREATE_DATE > DateADD(mi, -5, Current_TimeStamp)