How to check empty data

Describe the problem/error/question

I want to continue only if data exist. How can I add this without having data from previous node?

What is the error message (if any)?

Please share your workflow

(Select the nodes on 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:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

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:

Hi @Sebastian1

You can simply do this with is not empty condition inside the IF Node.

If there is value provided, it’ll go to TRUE branch, If no value then FALSE branch.

Hi @mcnaveen, thank you for your reply. I understand how todo it inside the If node but how can I adress the Data from previous node if there is no Data with the test coming? So far I add a test data in the first node and let it run though all nodes until I see the data in the if node. But Can I simply say if data is coming from previous node then do 1 if not then do 2 for example?

On the previous node enable Always Output Data and check for an array in If node

1 Like

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