gpt4 book ai didi

SQL 错误 : ORA-00933: SQL command not properly ended 00933. 00000 - "SQL command not properly ended"

转载 作者:行者123 更新时间:2023-12-04 17:33:07 39 4
gpt4 key购买 nike

我浏览了这个网站,找不到类似的场景。我正在尝试运行以下代码

SELECT st.storeid, s.noofitems
FROM salestrnsaction AS st, soldvia AS s
WHERE st.tid = s.tid
ORDER BY noofitems ASC;

并且仍然收到“SQL 命令未正确结束”错误。

更具体地说,这是我收到的消息。
SELECT st.storeid, s.noofitems
FROM salestrnsaction AS st, soldvia AS s
WHERE st.tid = s.tid
ORDER BY noofitems ASC
Error at Command Line : 287 Column : 22
Error report -
SQL Error: ORA-00933: SQL command not properly ended
00933. 00000 - "SQL command not properly ended"
*Cause:
*Action:

谢谢。

最佳答案

您在使用 ORACLE 对吗?使用 AS在 FROM 子句中的别名在 Oracle 中无效。
请避免使用 AS 为表提供别名。

只需在表后写别名。

SELECT st.storeid, s.noofitems
FROM salestrnsaction st, soldvia s
WHERE st.tid = s.tid
ORDER BY s.noofitems ASC;

关于SQL 错误 : ORA-00933: SQL command not properly ended 00933. 00000 - "SQL command not properly ended",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36706780/

39 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com