Google Sheets: ERROR: Could not find column for key

Context: I am trying to read a list of potential sponsor domains and write the emails fetched by uProc back to the sheet.

This is a screenshot of the sheet

After I fetch the emails, I transform the data model as follows

"ID": 2,
"Name": "Domainr",
"Website": "",
"Emails": "[email protected],[email protected],[email protected],[email protected]"
"ID": 3,
"Name": "James Homer",
"Website": "",
"Emails": ","
"ID": 4,
"Name": "SANTiHANS LLC",
"Website": "",
"Emails": "[email protected],"

I then tried to update the sheet with the following configuration

However, I got the following error

ERROR: Could not find column for key "Emails"!

Error: Could not find column for key "Emails"!
    at GoogleSheet.updateSheetData (/usr/local/lib/node_modules/n8n/node_modules/n8n-nodes-base/dist/nodes/Google/Sheet/GoogleSheet.js:135:19)
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
    at async Object.execute (/usr/local/lib/node_modules/n8n/node_modules/n8n-nodes-base/dist/nodes/Google/Sheet/GoogleSheets.node.js:885:34)
    at async /usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/src/WorkflowExecute.js:395:47

From the original screenshot, the email key exists. I don’t know what I’m doing wrong

The JSON you pasted it. Where is that coming from?

The finalize data model set node merges the data from google sheets and uProc

Hi @arsalagrey

I think the best way is define Key to ID to update row. This is the row identifier and always exists.