执行sql时出现错误 extraneous input ';' expecting EOF near '<EOF>'

调用jdbc执行hive sql时出现错误

Error while compiling statement: FAILED: ParseException line 5:22 extraneous input ';' expecting EOF near '<EOF>'

错误原因是因为sql语句中多了分号

执行脚本时需要在sql后面添加分号

但是调用jdbc执行sql语句时,不可以在语句用分号结束

原文地址:https://www.cnblogs.com/Dhouse/p/5919386.html