Skip to content
Advertisement

Update Airflow XCOM value in Database

How can I update any value in the XCOM table with:

session.query(XCom)

Is there any option like the following?

session.query(XCom).filter(XCom.dag_id == "mydag123").update()

Advertisement

Answer

I solved my own question:

session.query(XCom).filter(XCom.dag_id == "mydag123") 
.update({XCom.value:b'new value'})

User contributions licensed under: CC BY-SA
6 People found this is helpful
Advertisement