当我尝试解析此语句时,我收到ORA-00907
错误。关于我做错了什么想法?
提前致谢!
DELETE
FROM teams
WHERE is_old=0
AND tm_counter NOT IN (SELECT MIN(dup.tm_counter)
FROM teams AS dup
GROUP BY dup.name, dup.squad, dup.region);
答案 0 :(得分:4)
在Oracle中,您不能在表别名之前使用AS
,而只能在列别名之前使用FROM teams AS dup
。所以,改变这一部分:
FROM teams dup
到此:
{{1}}