SOL-C01 · Question #175
A Snowflake table 'product catalog' exists with columns 'product id', 'product_name', and 'price'. You have a pipe-delimited file in an external stage named 's3 stage' containing product data, but som
Sign in or unlock SOL-C01 to reveal the answer and full explanation for question #175. The question stem and answer options stay visible for context.
Question
A Snowflake table 'product catalog' exists with columns 'product id', 'product_name', and 'price'. You have a pipe-delimited file in an external stage named 's3 stage' containing product data, but some rows have missing values for the 'price' column. You want to load the data, replacing missing prices with a default value of 0. Which approach is the MOST appropriate to handle missing values during the 'COPY INTO' operation?
Options
- AModify the file format options to automatically replace null values with 0.
- BUse a transformation within the `COPY INTO' statement to replace null values with 0.
- CLoad the data into a staging table, then use a SQL 'UPDATE statement to replace null prices with
- DUse the 'ON_ERROR = SKIP_FILE' option to skip any file with missing prices.
- EThe 'COPY INTO' command cannot handle missing values; pre-processing is always required.
Unlock SOL-C01 to see the answer
You've previewed enough free SOL-C01 questions. Unlock SOL-C01 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.