1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
|
# name: test/sql/copy/csv/csv_line_too_long.test
# description: Test that verifies that the CSV has long lines and properly errors that
# group: [csv]
statement ok
PRAGMA enable_verification
statement ok
CREATE TABLE T1 (name VARCHAR);
foreach header true false
statement error
COPY T1(name) from '{DATA_DIR}/csv/line_too_long.csv.gz' (DELIMITER ',', HEADER ${header} , COMPRESSION gzip, ALLOW_QUOTED_NULLS false);
----
Maximum line size of 2000000 bytes exceeded
statement error
COPY T1(name) from '{DATA_DIR}/csv/line_too_long_with_newline.csv.gz' (DELIMITER ',', HEADER ${header} , COMPRESSION gzip, ALLOW_QUOTED_NULLS false);
----
Possible Solution: Change the maximum length size, e.g., max_line_size=2097165
statement error
COPY T1(name) from '{DATA_DIR}/csv/multiple_line_too_long.csv.gz' (DELIMITER ',', HEADER ${header} , COMPRESSION gzip, ALLOW_QUOTED_NULLS false);
----
Possible Solution: Change the maximum length size, e.g., max_line_size=2097165
endloop
|