I am facing issue while I am trying to do a copy into from S3 stage (with column headers but in different order than that of target snowflake table) to snowflake db using this copy into command
COPY INTO db.schema.table FROM @stage/file.csv
FILE_FORMAT=(TYPE= CSV field_delimiter ='|' SKIP_HEADER =1) ;
Is there any way that we can push the files in the similar order as of target table in snowflake?
I tried using SELECT as well in the COPY command, but no luck, as we ave to hard code the order. This is tedious and is not what Ia m looking for as I need to write for many tables.
I see there is
MATCH_BY_COLUMN_NAME = CASE_SENSITIVE | CASE_INSENSITIVE | NONE
copy option, but it is not supporting for CSV file or structured data