With a FILES() function, how do I disable the sche...
# questions-and-troubleshooting
p
With a FILES() function, how do I disable the schema detection for CSV? I just want to import as text. Is it by setting the
auto_detect_sample_rows
to zero? https://docs.starrocks.io/docs/sql-reference/sql-functions/table-functions/files/#schema_detect
setting auto_detect_sample_rows='0' means there are no columns, so this is no good
r
The
auto_detect_sample_rows
if set to 0 does not sample anything, that's why it can't deduce any schema, which lead to 0 column. What are you trying to do? Are you trying to query one line as single row with one column?
I'm not sure what you mean by import as text, but if you're trying to fit a whole file into a single column, you can still use CSV and change the delimiter
Copy code
"csv.column_separator"="\0", 
    "csv.row_delimiter"="\0",
p
I'm trying to import all columns as text, not detected types.
I was able to work around this by messing with the
strict_mode
settings