DataTable 'upsert' is broken in 1.113.3

WHen I use an upsert to a three column table specifying two of the columns the rows are inserted not updated even when 2 of the three values exist. For example if I start with:
ID Domain Header Value
1 Bim Authn 1234
and perform the upsert on Domain=Bim & Header=Authn setting the Value to a new string I get two rows, not one
ID Domain Header Value
1 Bim Authn 1234
2 Bim Authn 5678
The createdAt timestamp for Row 2 is different from the creation timestamp of RowID 1, so this isn’t being treated as a time series.
Given that there are three columns, specifying two of them and assigning a new value for the third should update the th ird in place, not add a new row with the two fixed values duplicated and a new value of the third.

Describe the problem/error/question

What is the error message (if any)?No error returned, I just end up with two rows having identical values for the lookup and a differing value for the updated value.

Please share your workflow

(Select the nodes on {
  "nodes": [
    {
      "parameters": {
        "operation": "upsert",
        "dataTableId": {
          "__rl": true,
          "value": "Gs5dGcKafkPWhGT2",
          "mode": "list",
          "cachedResultName": "HTTP Headers",
          "cachedResultUrl": "/projects/MMVRo9L4qTSnSwAF/datatables/Gs5dGcKafkPWhGT2"
        },
        "matchType": "allConditions",
        "filters": {
          "conditions": [
            {
              "keyName": "Domain",
              "keyValue": "LawRuler"
            },
            {
              "keyName": "Header",
              "keyValue": "Authentication"
            }
          ]
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "Value": "={{ $json.Authorization }}",
            "Domain": "LawRuler",
            "Header": "Authorization"
          },
          "matchingColumns": [],
          "schema": [
            {
              "id": "Domain",
              "displayName": "Domain",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "Header",
              "displayName": "Header",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "Value",
              "displayName": "Value",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        }
      },
      "type": "n8n-nodes-base.dataTable",
      "typeVersion": 1,
      "position": [
        352,
        -80
      ],
      "id": "7f6fea6d-9c56-46da-bafd-2f7a00e01306",
      "name": "Upsert row(s)"
    }
  ],
  "connections": {},
  "pinData": {},
  "meta": {
    "instanceId": "b63a42e5331cc5aba735306f631ed22e73515e65e5bd3692c0896eace4fcee37"
  }
}your canvas and use the keyboard shortcuts CMD+C/CTRL+C and CMD+V/CTRL+V to copy and paste the workflow.)

Share the output returned by the last node

Information on your n8n setup

  • n8n version: 1.113.3
  • Database (default: SQLite): DataTable
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app): execution of local n8n via web.
  • Operating system: linux 6.13.1-1-default (OpenSUSE Tumbleweed).

P.S., if I do not specify the Doman & Header fixed values in the upsert operation then I get a new row with NULL for the Domain and Header.

The KwikFix for this is taking the single row with the maximum created timestamp but that isn’t a good long-term solution.

Yes the bug is still present as of version 1.117.3
I would recommend using the if row exists mode, and inserting and updating based on the conditions.

I hope this is fixed soon.