meel-ayush commented on code in PR #76828:
URL: https://github.com/apache/airflow/pull/76828#discussion_r4634611993
##########
providers/common/sql/src/airflow/providers/common/sql/operators/sql.py:
##########
@@ -503,6 +503,10 @@ class SQLExecuteQueryOperator(BaseSQLOperator):
:param requires_result_fetch: (optional) if True, ensures that query
results are fetched before
completing execution. If `do_xcom_push` is True, results are fetched
automatically,
making this parameter redundant. (default: False).
+ :param validate_sql: (optional) if True, validates SQL syntax locally
before execution (default: False).
+ :param check_partition_filters: (optional) if True, checks for partition
filters and unbounded queries (default: False).
+ :param partition_columns: (optional) column names or mapping of table to
column names required in WHERE clauses.
+ :param dialect: (optional) SQL dialect name to use for validation. If
None, detected from hook.
Review Comment:
Hook autodetection is the default and covers standard hooks (Postgres,
Snowflake, BigQuery, MySQL, Trino).
The explicit parameter is an override for generic transport hooks like
JdbcHook and OdbcHook where conn_type returns "jdbc" or "odbc" (transport
protocols, not SQL dialects), masking the actual engine (e.g. Oracle or T-SQL).
It also covers dialect variants like running Spark SQL queries through a Hive
connection.
--
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]