Categories: System
LAST_QUERY_ID
Returns the ID for the most recently executed query in the current session. This function cannot be used in a reflection.
Syntax
LAST_QUERY_ID() → varchar
Examples
LAST_QUERY_ID exampleSELECT LAST_QUERY_ID()
-- 1f1ae232-55c0-9df3-caa9-2c52deecf300
SELECT LAST_QUERY_ID
-- 1f1ae232-55c0-9df3-caa9-2c52deecf300
Usage Notes
This function can be called without the parentheses.
Was this page helpful?
Glad to hear it! Thank you for your feedback.
Sorry to hear that. Thank you for your feedback.