My fields are not being mapped correctly

My fields are not being mapped correctly

I’m having trouble mapping fields correctly in my n8n workflow. My workflow retrieves data from a Google Sheet, processes it using multiple AI agents, and then writes the manipulated data to another Google Sheet.

The issue arises when trying to map the BRANCH variable to a field in the final Google Sheet module. When I drag the BRANCH variable into the target field, I either get undefined or an invalid syntax error.

Previously, I encountered a similar issue when mapping data from the first module to a Google Sheet, but I resolved it using .first(). However, .first() and $('module name') are not working in this case.

The error message:

  • undefined
  • invalid syntax

My workflow

Information on your n8n setup

  • n8n version: 1.77

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

$json can only access the output of the previous node. Use the full $(‘node name’) notation to access nodes further back the chain.