So forgive me if this is a dumb post, as Ive only recently started using n8n, but I believe Im not getting the desired behavior from the IF node. Anything I do results in a “true” output. In the first image, value 1 is set to 10, and value 2 is set to 0, and the comparison is set to “equals” and returns true. To the best of my knowledge 10 == 0 should be false.
Hi @sterling_baldwin, welcome to the community. No question is a dumb question, it usually means that the documentation is lacking and that we should work to improve it
Regarding your question, I see in the screenshot that it shows Results: 0 on true since the Condition is false. That is expected. If you click on true and select false from the dropdown list, you should see Results: 1 or something similar depending on the workflow. I’ve recorded a GIF to showcase this.
You can see the IF node is action with some data in the workflow by following the Creating Your First Workflow tutorial. You can also learn more about the IF node in our documentation.
OK, I think the issue is I just dont understand what the meaning of the “results” count and the “output” drop down are. I added a couple execute nodes attached to “true” and “false” output, and ran the workflow.
The “Output” drop down decides which data to display (so really just decides what data to display, it does not change the behavior). Either the data which will be output on the “true” output or the data which will be output on the “false” output.
Behind “Results” it will display the number of items it will output. The number it displays depends on the “Output” selector. So it will change if you change from “true” to “false”.