Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SQL workbench Error while connecting to Redshift

Tags:

I am trying to create a table in aws redshift using sqlwork bench. I am able to connect redshift but while executing below script, I am getting connection aborted error. Please let me know if any one has any solution.

CREATE  TABLE actual_report (
  type1 varchar(40),
  Jj_calendar_Order_Month varchar(40),
  Jj_Calendar_Order_Year varchar(40),
  Product_major_Code_description varchar(40),
  Product_minor_Code varchar(40),
  Product_part_number varchar(40),
  Product_Minor_Description varchar(40),
  Order_Quantity decimal(20),
  Order_Item_Unit_Price decimal(10,2),
  country varchar(40))

An error occurred when executing the SQL command: CREATE TABLE actual_report ( type1 varchar(40), Jj_calendar_Order_Month varchar(40), Jj_Calendar_Order_Year varchar(40), Product_major_Code_descripti...

Amazon Invalid operation: current transaction is aborted, commands ignored until end of transaction block; Execution time: 0.22s 1 statement failed.

like image 957
user3858193 Avatar asked Mar 23 '15 23:03

user3858193


People also ask

Can MySQL workbench connect to Redshift?

With access to live Redshift data from MySQL Workbench, you can easily query and update Redshift, just like you would a MySQL database.


1 Answers

I'm using SQL Workbench, and by default autocommit is off. I run the SQL command below to turn on autocommit, otherwise the transaction will not be committed to database. Just for your reference.

SET autocommit ON
like image 116
keypoint Avatar answered Oct 20 '22 10:10

keypoint