diff --git a/test/sql/scanner/mixed_numeric.test b/test/sql/scanner/mixed_numeric.test index 7023ba5..e8e9019 100644 --- a/test/sql/scanner/mixed_numeric.test +++ b/test/sql/scanner/mixed_numeric.test @@ -11,20 +11,6 @@ select * from sqlite_scan('data/db/mixed_data_numeric.db', 'tbl'); ---- Invalid type in column "a": expected float or integer, found "hello" of type "text" instead. -# using the all_varchar option, without the setting -statement ok -ATTACH 'data/mixed_data_numeric.db' as mydb (TYPE sqlite, all_varchar TRUE); - -query I -select * from mydb.tbl; ----- -42 -hello -NULL - -statement ok -DETACH mydb; - statement ok SET sqlite_all_varchar=true @@ -35,13 +21,3 @@ select * from sqlite_scan('data/db/mixed_data_numeric.db', 'tbl'); hello NULL -# using the setting, not the all_varchar option -statement ok -ATTACH 'data/db/mixed_data_numeric.db' as mydb (TYPE sqlite); - -query I -select * from mydb.tbl; ----- -42 -hello -NULL diff --git a/test/sql/storage/attach_mixed_numeric.test b/test/sql/storage/attach_mixed_numeric.test new file mode 100644 index 0000000..d1902cd --- /dev/null +++ b/test/sql/storage/attach_mixed_numeric.test @@ -0,0 +1,31 @@ +require sqlite_scanner + +# load from a database with a numeric column that has mixed types + +# using the all_varchar option, without the setting +statement ok +ATTACH 'data/mixed_data_numeric.db' as mydb (TYPE sqlite, all_varchar TRUE); + +query I +select * from mydb.tbl; +---- +42 +hello +NULL + +statement ok +DETACH mydb; + +statement ok +SET sqlite_all_varchar=true + +# using the setting, not the all_varchar option +statement ok +ATTACH 'data/mixed_data_numeric.db' as mydb (TYPE sqlite); + +query I +select * from mydb.tbl; +---- +42 +hello +NULL