ExamGecko
Question list
Search
Search

Question 651 - COF-C02 discussion

Report
Export

What would cause different results to be returned when running the same query twice?

A.
SAMPLE is used and the seed is set
Answers
A.
SAMPLE is used and the seed is set
B.
sample is used and the seed is not set.
Answers
B.
sample is used and the seed is not set.
C.
Fraction-based sampling is used.
Answers
C.
Fraction-based sampling is used.
D.
Fixed-size sampling Is used.
Answers
D.
Fixed-size sampling Is used.
Suggested answer: B

Explanation:

When using the SAMPLE clause in a query, if the seed is not set, Snowflake will use a different random seed for each execution of the query. This results in different rows being sampled each time, leading to different results. Setting a seed ensures that the same rows are sampled each time the query is run.

References:

Snowflake Documentation: Sampling

asked 23/09/2024
Eric De La Vega
41 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first