gpt4 book ai didi

GridDB - Running Insert query in griddb shell returns an error [240008:SQL_COMPILE_COLUMN_NOT_FOUND](GridDB-在Griddb外壳中运行INSERT查询返回错误[240008:SQL_COMPILE_COLUMN_NOT_FOUND])

转载 作者:bug小助手 更新时间:2023-10-25 11:52:05 26 4
gpt4 key购买 nike



I've created a table in griddb using this query:

我已经使用以下查询在Griddb中创建了一个表:


CREATE TABLE tbl1 (
id INTEGER NOT NULL,
name STRING
);

When I try to insert a record using insert query it returns this error:

当我尝试使用Insert Query插入记录时,它返回以下错误:



D20332: An unexpected error occurred while executing a SQL. :

msg=[[240008:SQL_COMPILE_COLUMN_NOT_FOUND] Column not found (name=John
Doe) on updating (sql="insert INTO tbl1 (id, name) VALUES (1, "John
Doe")") (db='public') (user='admin') (appName='gs_sh')
(clientId='ddd01cd4-3370-4a12-a62f-ce3a652540d5:2')
(source={clientId=3, address=127.0.0.1:54084})
(address=127.0.0.1:20001, partitionId=246)]



This is my insert query:

这是我的插入查询:


INSERT INTO tbl1 (id, name) VALUES (1, "John Doe");

What am I doing wrong here?

我到底做错了什么?


更多回答

Try single quotes instead, 'John Doe'. (Double quotes are for delimited identifiers, e.g. a column named John Doe.)

试着用单引号,‘John Doe’。(双引号用于分隔的标识符,例如名为John Doe的列。)

优秀答案推荐

I recently encountered a similar error and followed the comment by jarlh

我最近遇到了一个类似的错误,Jarlh跟随了我的评论


Using a single quote helps fix the error.
Try using;

使用单引号有助于修复错误。试着使用;


INSERT INTO tbl1 (id, name) VALUES (1, 'John Doe');

OR


INSERT INTO tbl1 VALUES (1, 'John Doe');

更多回答

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