You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "Romeo Kienzer (Jira)" <ji...@apache.org> on 2021/01/07 16:01:00 UTC

[jira] [Created] (NIFI-8122) Support "upsert" functionality in PutSQL processor

Romeo Kienzer created NIFI-8122:
-----------------------------------

             Summary: Support "upsert" functionality in PutSQL processor
                 Key: NIFI-8122
                 URL: https://issues.apache.org/jira/browse/NIFI-8122
             Project: Apache NiFi
          Issue Type: New Feature
          Components: Extensions
    Affects Versions: 1.12.1
            Reporter: Romeo Kienzer


The ConvertJSONtoSQL processor doesn't Support "upsert" functionality, only insert, update and delete. As the ConvertJSONtoSQL already has a working jdbc connection to query metadata on the target table I think it would be straightforward to query the target table to decide if on a given row in a flow file an insert or an update has to be created.

I don't know if I'm getting something completely wrong here, but the Nifi community only speaks about "workarounds" when it comes to upsert. So this way we would have a clean implementation (although it requires one additional query roundtrip per row), but at least there should be an index on the key fields



--
This message was sent by Atlassian Jira
(v8.3.4#803005)