代码
现象
ParseException line 6:4 cannot recognize input near 'percent' 'String' 'COMMENT' in column name or primary key or foreign key
23/11/13 11:52:57 ERROR org.apache.hadoop.hive.ql.Driver: FAILED: ParseException line 6:4 cannot recognize input near 'percent' 'String' 'COMMENT' in column name or primary key or foreign key
org.apache.hadoop.hive.ql.parse.ParseException: line 6:4 cannot recognize input near 'percent' 'String' 'COMMENT' in column name or primary key or foreign key
原因
在hive中row和percent都是关键字,所以会报错文章来源:https://www.toymoban.com/news/detail-809522.html
更改后的代码
文章来源地址https://www.toymoban.com/news/detail-809522.html
到了这里,关于hive里因为列名用了关键字导致建表失败的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!