Count the number of a keyword in Google Sheet and report the error when it falls short

  • **n8n version:**1.81.4
  • **Database (default: SQLite):**postgreSQL
  • n8n EXECUTIONS_PROCESS setting (default: own, main):=own
  • Running n8n via (Docker, npm, n8n cloud, desktop app):=zeabur
  • Operating system:
    This is my workflow, I hope he can check the number of times “No” under the field “completed” in my trial balance, if any trial balance has less than 5 times “No”, report an error and notify me, otherwise there is no need to remind me, but I use AI to teach me to write it without success

You don’t need an error trigger.

There would be a few ways to do this, here is one:

Or you could replace aggregate with code node that runs “once for all items”:

You could also change the filter to be an IF node, which allows to change paths depending on the condition, allowing for other actions to occur if 5 wasn’t counted.

Sorry, I don’t understand what the difference between the two methods is? Can you please tell me?

In addition, I can do the initial test now, and he will send me a message when the conditions are met, but I don’t know which work forms are wrong, how can I fix this?

Thank you for your efforts

Either method should work the same. I was just giving options.

Unsure on your second question tho, if you could explain more, thanks.

I mean as in my workflow above, my google sheet table 1 and google sheet table 2 will be in the same function, so in if node judgement, he will only tell me there is an error, but won’t tell me which google sheet is out of order, is there any good way to solve this problem? Any good way to solve this problem?

Any luck so far?

Thanks for your concern, for now all I can think of is to branch them out and make a flow for each google sheet so they can each tell me which one is the problem :smiley:

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.