
Explanation:
The correct way to query a global temporary view in SQL Server is by using the global_temp prefix followed by the view name, as in SELECT * FROM global_temp.orders_vw. This is because global temporary objects in SQL Server are referenced with global_temp, not with variations like gbl_temp, gbl_temporary, or gbl_tmp, nor with global_temporary. Using the correct prefix ensures the query recognizes and accesses the global temporary view properly.
Ultimate access to all questions.
A junior data engineer has created a global temporary view named orders_vw for a specific task. However, when attempting to query this view with SELECT * FROM orders_vw, an error occurs. As a senior data engineer, what would you advise your colleague to correct in order to successfully execute this query?
A
SELECT * FROM gbl_tmp.orders_vw
B
SELECT * FROM global_temp.orders_vw
C
SELECT * FROM gbl_temp.orders_vw
D
SELECT * FROM global_temporary.orders_vw
E
SELECT * FROM gbl_temporary.orders_vw
No comments yet.