MYSQL table creation?


#1

Hi Team,

I am getting error while creating table in retail_db in MYSQL. Could you please share me where to create table and password to sqoop that table.


#2

@Amit1,

Hope this discussion will help you.


#3

Hi Sravan,

As suggested by you, I have created order_test table in retail_export schema and able to insert and select the data. But while sqoop this table to hadoop I am getting error as ‘retail_export.order_test’ doesn’t exist . Could you please look into it.

18/09/03 01:34:36 ERROR manager.SqlManager: Error executing statement: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Table ‘retail_export.order_test’ doesn’t exist
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Table ‘retail_export.order_test’ doesn’t exist
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)


#4

@Amit1,

It is saying that, table_doesnt exist.
Have to create a table in retail_export.


#5

Hi Sravan,

As I mentioned already, I have created table in retail_export and able see the data as below but getting error in sqooping.

mysql> select * from retail_export.order_test;
±---------±--------------------±------------------±----------------+
| order_id | order_date | order_customer_id | order_status |
±---------±--------------------±------------------±----------------+
| 1 | 2013-07-25 00:00:00 | 11599 | CLOSED |
| 2 | 2013-07-25 00:00:00 | 256 | PENDING_PAYMENT |
| 3 | 2013-07-25 00:00:00 | 12111 | COMPLETE |
| 4 | 2013-07-25 00:00:00 | 8827 | CLOSED |
| 5 | 2013-07-25 00:00:00 | 11318 | COMPLETE |
| 6 | 2013-07-25 00:00:00 | 7130 | COMPLETE |
| 7 | 2013-07-25 00:00:00 | 4530 | COMPLETE |
| 8 | 2013-07-25 00:00:00 | 2911 | PROCESSING |
| 9 | 2013-07-25 00:00:00 | 5657 | PENDING_PAYMENT |
| 10 | 2013-07-25 00:00:00 | 5648 | PENDING_PAYMENT |
| 11 | 2013-07-25 00:00:00 | 5657 | COMPLETE |
±---------±--------------------±------------------±----------------+


#6

@Amit1,

Can you share the sqoop command that you are trying.