uranusjr commented on code in PR #23971:
URL: https://github.com/apache/airflow/pull/23971#discussion_r886324507


##########
airflow/hooks/dbapi.py:
##########
@@ -188,25 +206,21 @@ def run(self, sql, autocommit=False, parameters=None, 
handler=None):
                 self.set_autocommit(conn, autocommit)
 
             with closing(conn.cursor()) as cur:
-                results = []
                 for sql_statement in sql:
+                    results = []
                     self._run_command(cur, sql_statement, parameters)
                     if handler is not None:
                         result = handler(cur)
                         results.append(result)

Review Comment:
   Makes sense, and I think this matches the current behaviour implemented by 
various hooks (or at least most of them).



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to