eladkal edited a comment on pull request #22391: URL: https://github.com/apache/airflow/pull/22391#issuecomment-1074404405
> Can't we just supply a list of SQL statements to the existing operator? Yes but the goal is to support users who pass string composed of multiple query like: `SELECT 1; SELECT 2;` Most DBs knows how to execute it without any problem (MySQL, PostgresSQL etc..) others like Trino, Presto, Snowflake, Redshift can handle only 1 statement per query (most of the times? I guess there are exceptions with Do blocks and maybe others?) anyway we can always ask users to pass it as `['SELECT 1', 'SELECT 2']` but that is not that nice (Think of very very very large SQLs) and also note that you can't use the list solution with templating. Consider you want to do ``` RedshiftSQLOperator( ..., sql=my_queries.sql ) ``` when `my_queries.sql` contains multiple statements. -- 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]
