oracle ORA-00984: 此处不允许列

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/17054221/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-10 05:05:24  来源:igfitidea点击:

ORA-00984: column not allowed here

oracleoracle10g

提问by George Murphy

I am doing a simple Oracle INSERTand I keep getting this error: [Err] ORA-00984: column not allowed here

我正在做一个简单的Oracle INSERT,但我不断收到此错误: [Err] ORA-00984: column not allowed here

INSERT INTO MY.LOGFILE
(id,severity,category,logdate,appendername,message,extrainfo)
VALUES
(
"dee205e29ec34",
"FATAL",
"facade.uploader.model",
"2013-06-11 17:16:31",
"LOGDB",
NULL,
NULL
)

回答by Quassnoi

Replace double quotes with single ones:

用单引号替换双引号:

INSERT
INTO    MY.LOGFILE
        (id,severity,category,logdate,appendername,message,extrainfo)
VALUES  (
       'dee205e29ec34',
       'FATAL',
       'facade.uploader.model',
       '2013-06-11 17:16:31',
       'LOGDB',
       NULL,
       NULL
       )

In SQL, double quotes are used to mark identifiers, not string constants.

在 SQL 中,双引号用于标记标识符,而不是字符串常量。