Uploaded image for project: 'Apache Airflow'
  1. Apache Airflow
  2. AIRFLOW-2638

dbapi_hook: insert_rows: support replace into

    XMLWordPrintableJSON

    Details

    • Type: New Feature
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.10.0
    • Component/s: database
    • Labels:
      None

      Description

      Sometimes, you want to use dbapi_hook's insert_rows method, but with "REPLACE INTO", as some values might already exist (while iterating over the same data). This PR adds a `replace` optional parameter, that changes the query to "REPLACE INTO" instead of "INSERT INTO".

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              flokli Florian Klink
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: