exam questions

Exam DP-203 All Questions

View all questions & answers for the DP-203 exam

Exam DP-203 topic 1 question 56 discussion

Actual exam question from Microsoft's DP-203
Question #: 56
Topic #: 1
[All DP-203 Questions]

DRAG DROP -
You plan to create a table in an Azure Synapse Analytics dedicated SQL pool.
Data in the table will be retained for five years. Once a year, data that is older than five years will be deleted.
You need to ensure that the data is distributed evenly across partitions. The solution must minimize the amount of time required to delete old data.
How should you complete the Transact-SQL statement? To answer, drag the appropriate values to the correct targets. Each value may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.
NOTE: Each correct selection is worth one point.
Select and Place:

Show Suggested Answer Hide Answer
Suggested Answer:
Box 1: HASH -

Box 2: OrderDateKey -
In most cases, table partitions are created on a date column.
A way to eliminate rollbacks is to use Metadata Only operations like partition switching for data management. For example, rather than execute a DELETE statement to delete all rows in a table where the order_date was in October of 2001, you could partition your data early. Then you can switch out the partition with data for an empty partition from another table.
Reference:
https://docs.microsoft.com/en-us/sql/t-sql/statements/create-table-azure-sql-data-warehouse https://docs.microsoft.com/en-us/azure/synapse-analytics/sql/best-practices-dedicated-sql-pool

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
ClassMistress
Highly Voted 2 years, 5 months ago
I think it is Hash because the question refer to a Fact table.
upvoted 23 times
...
hereiamken
Highly Voted 1 year, 8 months ago
1. Hash -> Fact Table 2. DateKey -> for Partition
upvoted 17 times
...
dgerok
Most Recent 6 months, 4 weeks ago
1) HASH, because this is a fact table 2) OrderDateKey (simply see the partition values - these are dates)
upvoted 2 times
...
kkk5566
1 year, 2 months ago
the syntax is ok only for HASH & Datekey
upvoted 3 times
...
kumarsunny
1 year, 2 months ago
Why not 'Product Key' for partition? can anyone explain me please.
upvoted 1 times
MJamesP
1 year, 1 month ago
Because partitioning on the date key will help in deleting older data quickly since the older records' partition can be moved to a different table and the table truncated.
upvoted 4 times
...
...
VittalManikonda
1 year, 4 months ago
if it is round robin, there is no key to specify, so hash
upvoted 2 times
...
[Removed]
1 year, 7 months ago
It must be HASH because of syntax.
upvoted 5 times
...
SHENOOOO
1 year, 9 months ago
The Answer is correct
upvoted 3 times
...
astone42
1 year, 9 months ago
The answer is correct.
upvoted 2 times
...
DindaS
1 year, 9 months ago
Should be Round Robin as the requirement is to have the data evenly. the second one should be on the date
upvoted 3 times
auwia
1 year, 4 months ago
You would use Round-Robin for staging table and not Fact table.
upvoted 3 times
...
Ritik37
1 year, 7 months ago
It should, but they have given attributes. So only hash supports attribute
upvoted 1 times
...
...
allagowf
2 years ago
<distribution_option> ::= { DISTRIBUTION = HASH ( distribution_column_name ) | DISTRIBUTION = ROUND_ROBIN | DISTRIBUTION = REPLICATE } + fact table it's for sure ::: hash
upvoted 4 times
...
greenlever
2 years ago
data is distributed evenly across partitions and data is deleted once a year not frequently. So it should be Round-robin distribution.
upvoted 3 times
...
Rajashekharc
2 years, 2 months ago
Cannot be Round Robin, the syntax of distribution for round robin don't mention/include Column Name. So it has to be HASH
upvoted 5 times
...
Deeksha1234
2 years, 3 months ago
Answer is correct
upvoted 2 times
...
Dicer
2 years, 3 months ago
should be round robin because of distributed evenly.
upvoted 1 times
anks84
2 years, 2 months ago
syntax used is for HASH distribution.
upvoted 4 times
...
...
Franz58
2 years, 3 months ago
correct
upvoted 1 times
...
jebias
2 years, 6 months ago
I think the first answer should be Round-Robin as it should be distributed evenly. https://docs.microsoft.com/en-us/azure/synapse-analytics/sql-data-warehouse/sql-data-warehouse-tables-distribute
upvoted 2 times
Feljoud
2 years, 6 months ago
While you are right, that Round-Robin guarantees an even distribution, it is only recommended to use on small tables < 2 GB (see your link). Using the Hash of the ProductKey will also allow for an even distribution but in a more efficient manner. Also, the Syntax here would be wrong if you would insert Round-Robin. As in that case it would only say: "DISTRIBUTION = ROUND-ROBIN" (no ProductKey)
upvoted 26 times
dduque10
1 year, 11 months ago
For small tables is recommended replicated, not round robin
upvoted 1 times
...
sivva
2 years, 3 months ago
@Feljoud : Thanks for the clarification. Even I opted for Roundrobin, considering the keywords = "distributed evenly", but that's incorrect.
upvoted 2 times
...
nefarious_smalls
2 years, 6 months ago
You are exactly righty
upvoted 1 times
...
...
Massy
2 years, 6 months ago
the syntax is ok only for HASH
upvoted 6 times
...
Muishkin
2 years, 6 months ago
yes i think so too
upvoted 1 times
...
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago