GitHub user set92 added a comment to the discussion: Snowflake provider
(SnowflakeSqlApiOperator) - Not exposing query results with multiple queries
@potiuk From my point of view, what we are talking is a bug, since not all the
mechanisms work in the same way. The conversation if I'm going to use it or not
is another thing. The problem at hand is:
1. Running a single query -> Perfect, you only have a query, so the parent ID
is enough. ✅
2. Multiple queries -> In `_process_response` in SnowflakeHook we can see it is
prepared for it, since it evaluates, and returns the parent id, or the child
ids.
```
if resp_statement_handles := resp.get("statementHandles"):
statement_handles = resp_statement_handles
elif resp_statement_handle := resp.get("statementHandle"):
statement_handles = [resp_statement_handle]
else:
statement_handles = []
return {
"status": "success",
"message": resp["message"],
"statement_handles": statement_handles,
```
2.1. What I'm requesting is that the SnowflakeSqlApiOperator works in the same
way. It doesn't need to be for Airflow 2, only improve the product that is
Airflow for anyone to use it.
2.2. I think that implementation has a bug, because Snowflake doesn't add the
parent ID to the child IDs. I think as a user/developer you are going to expect
to have the parent ID AND the child IDs.
GitHub link:
https://github.com/apache/airflow/discussions/58689#discussioncomment-15086454
----
This is an automatically sent email for [email protected].
To unsubscribe, please send an email to: [email protected]