0

Am referring to this guide for writing my Sqoop2 client program: http://sqoop.apache.org/docs/1.99.2/ClientAPI.html

The example shows just setting the column names in table.columns property, it works fine but imports all the records in the table. I need to import only a set of records based on a simple where-clause sql. I tried setting table.sql property but it always return 'unacceptable' status on invoking SqoopClient.createJob(newJob). Anyone has run import successfully using free form query in Sqoop2 (CDH4.4.0)?

connectorForm.getStringInput("table.sql").setValue("select id,value from tableName where ${CONDITIONS} and groupid=123");
4

1 回答 1

1

除了由 SqoopClient.createJob() 返回的整体状态外,给定的 MJob 对象将通过状态消息进行更改。您可以通过遍历表单和输入并调用方法getValidationMessage()来获得有关您的工作有什么问题的精确错误消息。

于 2013-11-07T18:20:52.040 回答