Exam SnowPro Core All QuestionsBrowse all questions from this exam
Question 181

Which SQL commands, when committed, will consume a stream and advance the stream offset? (Choose two.)

    Correct Answer: C, D

    The SQL commands that consume a stream and advance the stream offset when committed are those that perform DML (Data Manipulation Language) operations, specifically INSERT and UPDATE operations. 'UPDATE TABLE FROM STREAM' and 'INSERT INTO TABLE SELECT FROM STREAM' fit this criterion. These commands read from the stream and make changes to a table, thereby advancing the stream offset when the transaction is committed.

Discussion
Raju039Options: AC

AC The stream position (i.e. offset) is advanced when the stream is used in a DML statement. The position is updated at the end of the transaction to the beginning timestamp of the transaction. The stream describes change records starting from the current position of the stream and ending at the current transactional timestamp. To ensure multiple statements access the same change records in the stream, surround them with an explicit transaction statement (BEGIN .. COMMIT). An explicit transaction locks the stream, so that DML updates to the source object are not reported to the stream until the transaction is committed.

Mubin_SikilkarOptions: AC

The stream position is advanced in DML statements i.e (Update,Insert) Hence A&C is the correct answer

halolOptions: AC

A&C DML

paknadeemOptions: AC

https://docs.snowflake.com/en/sql-reference/sql/create-stream.html

ludakaOptions: AC

A and C

SV1122Options: AC

The stream position (i.e. offset) is advanced when the stream is used in a DML statement. Insert, Update

Mallikharjuna452Options: AC

A and C are correct

pranaligOptions: AC

correct answer:AC

_yyuktaOptions: AC

A and C are correct

Colourseun

The following SQL commands, when committed, will consume a stream and advance the stream offset: A: SELECT FROM STREAM B: UPDATE TABLE FROM STREAM

SushY18

https://docs.snowflake.com/en/user-guide/streams-intro To advance the offset of a stream to the current table version without consuming the change data in a DML operation, complete either of the following actions: Recreate the stream (using the CREATE OR REPLACE STREAM syntax). Insert the current change data into a temporary table. In the INSERT statement, query the stream but include a WHERE clause that filters out all of the change data (e.g. WHERE 0 = 1).

SushY18

choose CD

EmiBOptions: AC

Could be ACE: A, C - The stream position (i.e. offset) is advanced when the stream is used in a DML statement. E - To ensure multiple statements access the same change records in the stream, surround them with an explicit transaction statement (BEGIN .. COMMIT).

psilvabrOptions: AC

DMLs advance Stream, so it is A and C.

KarBiswaOptions: AD

If committed after update it will move the offset position and same for insert

mlausOptions: AC

Insert, Delete, Update, so its AC