
Answer-first summary for fast verification
Answer: CREATE TABLE AS SELECT (CTAS)
The correct answer is B (CREATE TABLE AS SELECT - CTAS) because it directly creates a new table from the results of a query that joins tables from different sources (warehouse and lakehouse), automatically inferring column types from the source tables to ensure they match. This minimizes operations by performing table creation and data population in a single step. Option A (INSERT INTO) requires pre-existing table creation with explicit column definitions, adding extra operations. Option C (CREATE TABLE AS CLONE OF) cannot be used since it only clones existing tables, not query results from joins. Option D (CREATE MATERIALIZED VIEW AS SELECT) creates a view that automatically refreshes, which doesn't align with the requirement for a point-in-time table and may involve more operations over time.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
You have a Fabric tenant with a warehouse named DW1 and a lakehouse named LH1. DW1 contains a table named Sales.Product, and LH1 contains a table named Sales.Orders.
You plan to schedule an automated process to create a new point-in-time table named Sales.ProductOrder in DW1. This table will be built from the results of a query that joins Sales.Product and Sales.Orders.
You need to ensure the column types in Sales.ProductOrder match the column types in the source tables. The solution must minimize the number of operations required to create the new table.
Which operation should you use?
A
INSERT INTO
B
CREATE TABLE AS SELECT (CTAS)
C
CREATE TABLE AS CLONE OF
D
CREATE MATERIALIZED VIEW AS SELECT
No comments yet.