Hi!
My workflow copies the template file (with formatting, formulas, etc.) from Google Drive, adds _temp to the copy name and continues to operate on this copy. The problem is ‘Append or update row in sheet’ node is not taking document ID value passed by variable. Every time i try to pass that ID im getting expression highlighted in red and [undefined] as result. At the same time if and copy/paste that value as fixed its working like a charm.
For test purpose and even appended that to my json table and tried to read that from table… same result.
What am I doing wrong?
What is the error message (if any)?
Can not get sheet ‘By ID’ with a value of ‘undefined’
Please share your workflow
Share the output returned by the last node
Execution will continue even if the node fails
1 item
error
Can not get sheet ‘By ID’ with a value of ‘undefined’
What’s happening here is that your Google Sheets node is trying to read id_kopii, but the expression is returning undefined. That usually means the value didn’t get carried forward correctly from the Copy file → Set node.
Try this:
In your Get row(s) in sheet node, set Document ID like this:
{{ $('Copy file').item.json.id }}
This way you reference the actual output from the Copy file node instead of the value stored in your Set node.
If you really want to keep it in the Set node, make sure the property name matches exactly (your Set creates id_kopii, so you’d need):
{{ $('ZAPISZ ID KOPII PLIKU').item.json.id_kopii }}
Double-check the casing and spelling — even a small mismatch will cause [undefined].
The problem might be that the “Append or update row in sheet” node isn’t getting the document ID from the variable because it’s not ready yet, try checking if the “ZAPISZ ID KOPII PLIKU” node is working correctly and passing the ID, or test by manually setting the ID to see if it works, then fix the variable step by step. Let me know what you think.
Of course both drag from left list and rewrite.
I even tried to append that value to my json and read that directly from that. No luck.
@Zelite all nodes that should pass that value are work fine. Value is passed properly all the way to
google sheet node (i see it on the left side of panel).
I added addidional delay before sheet node to check if that change somenthing - no luck.
copy/paste id value (not variable) from left panel as fixed value makes it working so… the thing is that sheet node cannot properly resolve expresion or im doing something wrong.