Given a MySqlOperator and an sql query how do i pass a parameter and use it?
Here is my code which doesn't work. I am trying to pass the table name as a parameter.
UPDATE_SQL = "UPDATE {table} SET version=version+1 WHERE id='x'"
update_row = MySqlOperator(
dag=dag,
task_id='update_row',
mysql_conn_id=CONNECTION_ID,
parameters={'table': 'hello_world'},
database=MY_DATABASE,
sql=UPDATE_SQL,
)
I could not find any examples on how to use the parameters in the Operator.
