sqoop抽数报错Every derived table must have its own alias
报错如下:
ERROR manager.SqlManager: Error executing statement: java.sql.SQLSyntaxErrorException: Every derived table must have its own alias
修改前脚本:
--query "select * from (select APPNO,COMPANY from cs.gf_app t ) where $CONDITIONS " \
修改后脚本:
--query "select * from (select APPNO,COMPANY from cs.gf_app t ) t1 where $CONDITIONS " \
报错原因:
子查询需要加上别名