使用单引号错误,错误是"SELECt * FROM 'test3'"导致的,改成"SELECt * FROM "test3""og4j:WARN No appenders could be found for logger (org.apache.hadoop.metrics2.lib.MutableMetricsFactory).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
Exception in thread “main” org.apache.phoenix.exception.PhoenixParserException: ERROR 601 (42P00): Syntax error. Encountered “test3” at line 1, column 15.
at org.apache.phoenix.exception.PhoenixParserException.newException(PhoenixParserException.java:33)
需要将单引号改为双引号(' 改为 "),并转义,
# 错误 "SELECt * FROM 'test3'" # 正确 "SELECt * FROM "test3""
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)