PdfPrep.com

Which query should you execute?

You have a database named DB1 that contains a temporal table named Sales.Customers.

You need to create a query that returns the credit limit that was available to each customer in DB1 at the beginning of 2017.

Which query should you execute?

Answer: C

Explanation:

AS OF: Returns a table with a rows containing the values that were actual (current) at the specified point in time in the past.

Incorrect Answers:

A: CONTAINED IN has two parameters: CONTAINED IN (<start_date_time> , <end_date_time>)

B: We need at the exact specified point in time, not between two dates.

D: Not at all times

References: https://docs.microsoft.com/en-us/sql/relational-databases/tables/querying-data-in-a-system-versioned­temporal-table

Exit mobile version