Valid ARA-C01 Dumps shared by EduDump.com for Helping Passing ARA-C01 Exam! EduDump.com now offer the newest ARA-C01 exam dumps, the EduDump.com ARA-C01 exam questions have been updated and answers have been corrected get the newest EduDump.com ARA-C01 dumps with Test Engine here:
An Architect executes the following statements in order: CREATE TABLE emp (id INTEGER); INSERT INTO emp VALUES (1),(2); CREATE TEMPORARY TABLE emp (id INTEGER); INSERT INTO emp VALUES (1); Then executes: SELECT COUNT(*) FROM emp; DROP TABLE emp; SELECT COUNT(*) FROM emp; What will be the result?
Correct Answer: B
In Snowflake, temporary tables take precedence over permanent tables when they share the same name and exist in the same session. After creating the permanent emp table and inserting two rows, a temporary table with the same name is created. From that point forward in the session, all references to emp resolve to the temporary table, not the permanent one. The insert following the creation of the temporary table adds one row to the temporary table. Therefore, the first SELECT COUNT(*) FROM emp returns 1, reflecting the single row in the temporary table. When DROP TABLE emp is executed, it drops the temporary table first because it shadows the permanent table. After the temporary table is dropped, the permanent table named emp becomes visible again within the session. The final SELECT COUNT(*) FROM emp then queries the permanent table, which still contains the original two rows inserted earlier. This behavior is frequently tested in SnowPro Architect exams to validate understanding of object resolution precedence, session scope, and temporary object behavior. =========