Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Pre Create SQL Statement Syntax for Snowflake

nataliamiteva
8 - Asteroid

Hello, 

 

I got the following error when using the option to 'Delete Data & Append' in a Snowflake database: 

 

Error: Output Data (49): The COPY failed with error: Number of columns in file (46) does not match that of the corresponding table (47), use file format option error_on_column_count_mismatch=false to ignore this error
If you would like to continue loading when an error is encountered, use other values such as 'SKIP_FILE' or 'CONTINUE' for the ON_ERROR option. For more information on loading options, please run 'info loading_data' in a SQL client.

 

As suggested in the message, I then tried to include the syntax ON_ERROR=CONTINUE but maybe I am not writing it correctly?

 

nataliamiteva_1-1614281096818.png

 

I also tried with error_on_column_count_mismatch=false but got the same error.

 

Is anyone able to verify I am using the correct syntax?

 

Many thanks in advance!!

3 REPLIES 3
mceleavey
17 - Castor
17 - Castor

Hi @nataliamiteva ,

 

this appears to be a naming issue in that you haven't mapped the table names in the output script. Specifically you're missing a column from your output which is required when updating an existing record.

This ultimately prevents the SQL script from being written even if you're trying to override the error. 

Try including all columns, even if they're utterly unimportant.

 

M.

 

 



Bulien

nataliamiteva
8 - Asteroid

Thanks for the quick response !

 

I identified the column I was missing and created it with a formula tool, assigning NULL values in there. Got rid of the pre SQL statement and that worked.

 

I was having a bad Alteryx day .. 

mceleavey
17 - Castor
17 - Castor

Ha. We all have them...

 

no problem.gif



Bulien

Labels