airflow.providers.jdbc.operators.jdbc
¶
Module Contents¶
-
class
airflow.providers.jdbc.operators.jdbc.
JdbcOperator
(*, sql: str, jdbc_conn_id: str = 'jdbc_default', autocommit: bool = False, parameters: Optional[Union[Mapping, Iterable]] = None, **kwargs)[source]¶ Bases:
airflow.models.BaseOperator
Executes sql code in a database using jdbc driver.
Requires jaydebeapi.
See also
For more information on how to use this operator, take a look at the guide: JdbcOperator
- Parameters
sql (Can receive a str representing a sql statement, a list of str (sql statements), or reference to a template file. Template reference are recognized by str ending in '.sql') -- the sql code to be executed. (templated)
jdbc_conn_id (str) -- reference to a predefined database
autocommit (bool) -- if True, each command is automatically committed. (default value: False)
parameters (dict or iterable) -- (optional) the parameters to render the SQL query with.