Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Plain View
Sqoop >> mail # user >> Export in free from


Copy link to this message
-
Export in free from
Hi
  I want to  export data on the HDFS to the oracle database with
sqoop-1.4(sqoop-1.4.1-cdh4.1.2). However the columns betwean HDFS and
Oracle table  are  not exactly same to each other.

 For example,Data on HDFS:
-------------------------------------------------------------
| ID |      TIMEID          |   COLA  | COLB  |
-------------------------------------------------------------
| 6  |  201305221335    |    0        |  20      |
-------------------------------------------------------------

the Oracle table:
------------------------------------------------------------------------
| ID |      TIMEID          |   COLC  | COLB   | COLA |
------------------------------------------------------------------------
| 7  |  201305221335    |     kk      |  20      |  1       |
------------------------------------------------------------------------
Note:Additional COLC and unsame order.
I notice the sqoop export command:
--export-dir   HDFS source path for the export
--table  Table to populate.
It seams not to export the data to oracle in free from just as Free-form
Query Imports
using the --query argument.

Could I acheive that goal ?

Thanks very much

Regards
+
Jarek Jarcec Cecho 2013-05-22, 08:15
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB