DP-200 Exam QuestionsBrowse all questions from this exam

DP-200 Exam - Question 28


DRAG DROP -

You have a table named SalesFact in an enterprise data warehouse in Azure Synapse Analytics. SalesFact contains sales data from the past 36 months and has the following characteristics:

✑ Is partitioned by month

✑ Contains one billion rows

✑ Has clustered columnstore indexes

At the beginning of each month, you need to remove data from SalesFact that is older than 36 months as quickly as possible.

Which three actions should you perform in sequence in a stored procedure? To answer, move the appropriate actions from the list of actions to the answer area and arrange them in the correct order.

Select and Place:

Exam DP-200 Question 28
Show Answer
Correct Answer:
Exam DP-200 Question 28

Step 1: Create an empty table named SalesFact_work that has the same schema as SalesFact.

Step 2: Switch the partition containing the stale data from SalesFact to SalesFact_Work.

SQL Data Warehouse supports partition splitting, merging, and switching. To switch partitions between two tables, you must ensure that the partitions align on their respective boundaries and that the table definitions match.

Loading data into partitions with partition switching is a convenient way stage new data in a table that is not visible to users the switch in the new data.

Step 3: Drop the SalesFact_Work table.

Reference:

https://docs.microsoft.com/en-us/azure/sql-data-warehouse/sql-data-warehouse-tables-partition

Discussion

3 comments
Sign in to comment
LongBao
Apr 3, 2021

The answer is correct

AngelRio
Apr 20, 2021

1.- Copy the data to a new table by using CTAS. 2.- Switch partition... 3.- Drop new table

Mily94
Apr 25, 2021

are you sure? Why copy data?

rajneesharora
May 2, 2021

No need to copy data, when finally you have to drop the table, additionally, copying will take more time is not needed and is less efficient

rajneesharora
May 2, 2021

No need to copy data, when finally you have to drop the table, additionally, copying will take more time is not needed and is less efficient

memo43
May 16, 2021

No! you dont have to spend time for copying. to switch is more easy and take less time...

Kostali
Jul 19, 2021

1.- Copy the data to a new table by using CTAS. 2.- Switch partition... 3.- Drop new table