sqlcommand-line-interfacegriddb

Cannot query my container using the GridDB Shell?


I have a device container with the name 1cbfce15ec4d which houses some my data. I know for a fact there's data in there, but when I try a simple query in the griddb shell, I got the following error:

gs[public]> sql select * from 1cbfce15ec4d;
D20332: An unexpected error occurred while executing a SQL. : msg=[[240001:SQL_COMPILE_SYNTAX_ERROR] Parse SQL failed, reason = Syntax error: 1cbfce15ec4d; on executing query (sql="select * from 1cbfce15ec4d") (db='public') (user='admin') (appName='gs_sh') (clientId='a6d92f48-e558-440-86dd-a05e949fa726:1') (clientNd='{clientId=3, address=127.0.0.1:55744}') (address=127.0.0.1:20001, partitionId=983)]

I am not exactly sure what is going on here -- at first I assumed my data must be corrupt or empty, but that is not the case. It seems to be a case of the shell dying trying to process something about that container name.

Any ideas?


Solution

  • According to the manual :

    "If the name of a table or a column contains characters other than ASCII alphanumeric characters and underscore, or if the first character of the name is a number in a SQL statement, enclose the name with double quotation marks."

    Try select * from "1cbfce15ec4d"