DAA-C01 Question 80
Single answerUnstructured dataA retail analytics team stores product manuals and warranty PDFs in an internal stage in Snowflake. They want analysts to query metadata about these files, search document contents, and enrich a reporting table with extracted text from selected documents. The team wants to minimize data movement and avoid building a separate ingestion pipeline just to make the files queryable. Which approach best meets these requirements?
- A
Create a directory table on the stage for file-level metadata, define an external table over the staged files to expose each file as a row, and use document-processing functions/services in Snowflake to extract text when needed for downstream tables.
- B
Load every PDF into a VARIANT column using COPY INTO, because unstructured files must be fully loaded into Snowflake tables before any metadata or content can be queried.
- C
Create a materialized view directly on the stage to index file contents automatically, then join that materialized view to reporting tables for text extraction.
- D
Use only the stage and PATTERN filtering in queries, because staged unstructured files cannot expose file metadata through Snowflake objects and content extraction requires exporting files to an external OCR tool first.
Show answer and explanation
Correct answer: A
Explanation
The best answer is to use Snowflake-native features designed for unstructured data workflows: stages to store files, directory tables to expose file metadata, and external tables to make staged files queryable as rows. This supports analyst access to file inventories and selective processing without forcing a full ingestion pipeline. For extracting content from documents such as PDFs, Snowflake provides document-processing capabilities that can be used to enrich downstream tables while keeping the workflow inside Snowflake as much as possible. This approach matches best practices for minimizing data movement and operational overhead. Relevant Snowflake documentation areas include stages and directory tables, external tables for unstructured data patterns, and Snowflake document AI / text extraction features for processing unstructured documents.
- A. Correct.
Correct. This aligns with Snowflake's approach for unstructured data. A directory table on a stage provides file-level metadata such as relative path and file URLs. An external table can reference staged files so each file is represented as a row, enabling SQL-based discovery and filtering. For content extraction, Snowflake supports document AI / text extraction capabilities for unstructured documents, allowing downstream enrichment without first building a traditional ingestion pipeline for all files. This minimizes data movement and lets analysts work from staged files directly.
- B. Incorrect.
Incorrect. This reflects a common misconception that unstructured content must be loaded into a table before it becomes queryable. Snowflake supports querying staged files through stage metadata, directory tables, and external tables for unstructured data patterns. Loading all PDFs into VARIANT is not required and is generally not the right representation for binary document files such as PDFs.
- C. Incorrect.
Incorrect. Snowflake materialized views are not created directly on stages to automatically index unstructured file contents. Materialized views operate on query results from base tables or certain external tables under supported conditions, but they are not a native mechanism for document-content indexing from a stage. This option overstates automation that Snowflake does not provide in that form.
- D. Incorrect.
Incorrect. While PATTERN can help filter staged files, Snowflake does provide metadata access through stage-related objects such as directory tables, and it also provides in-platform capabilities to process unstructured documents. Exporting all files to an external OCR tool is not required for the scenario and would increase operational complexity and data movement.