title: Sqoop export using query
body: <p>We are trying to export the data from HIVE tables into HANA, able to export the data using <code>--hcatalog</code> table options in the Sqoop export command.</p>
  
  <p>But facing issues when trying to load the data using the query option with the where clause</p>
  
  <p>Is it possible to use the query option in the sqoop export command?</p>
  
  <p>My Sample scoop command is like below</p>
  
  <pre><code>sqoop export -D sqoop.export.records.per.statement=1 -D mapreduce.map.memory.mb=16384 -D mapreduce.map.java.opts=-Xmx16384m  --connect "jdbc:xxxxxx" --driver "com.sap.db.jdbc.Driver" --username "xxxxx" --password "xxxxxx" --table "hanaschema.table1" --query "select field1,substr(field2,1),field3,field4,from "hadoopschema.table" where field1 = 2017 and field3 = 4" --input-null-string '\\N' --input-null-non-string '\\N' --num-mappers 20 –-validate
  </code></pre>
  
  <p>Appreciate your help..</p>
  
  <p>Thanks
  Srini</p>