Getting Details About an Error¶
If the statement does not execute successfully, Snowflake returns one of the following response codes, as shown in the flow chart below:
As shown in this flow chart:
If the statement execution takes longer than the timeout period specified by the
timeoutfield in the request (or the timeout specified by the STATEMENT_TIMEOUT_IN_SECONDS parameter, if the
timeoutfield is not set), Snowflake returns the HTTP response code 408 with a QueryStatus object.
Use this object to get details about the cancellation of the statement execution.
If an error occurred when executing the statement, Snowflake returns the HTTP response code 422 with a QueryFailureStatus object.
You can get details about the error from this object.