Skip to main content

As a final check before creating an invoice in QBO I want a filter to stop the Zap if the number of Products found in the QBO ‘Find Product’ step is not equal to the number of ‘Amounts’ which is created in the previous Python code step. The code step strips out any fields amounting to 0 but I still want an additional check .  If there is a mismatch in these line items the names of the products will not align with the correct amounts in the invoice. I need a no code filter if possible but I do not see how to compare the number of items in each of these outputs.

Hi ​@Coburn123 

Filter help: https://zapier.com/apps/filter/integrations#help

 

In the Python step you can output a variable that is the # of the items.

You can use Formatter steps to get the number of items returned from QBO.

Then you can compare in a Filter step.


Thank you for the help Troy,  1.In Formatter/Numbers I don’t see a count option to use for the number ov QBO item . 2.  I do not have programming skills but used  AI prompts to eliminate 0 items from each line item.  How would you suggest adding a prompt to that step to find the # of items.


@Coburn123 

To use Formatter is a bit involved as it involves a series of steps to prep data to then be able to count the data.

 

Instead try this Zap action: AI by Zapier - Analyze and Return Data

You can instruct the AI to count the input field.

You can configure the output field to be a number.


That worked.  I created two AI by Zapier steps Step 1 Counts the number of  products found by QBO.   Step 2 Counts the number of values created by the Python code step. And finally I added a filter to compare the two outputs and stop the Zap if they are not matching, I don’t know if I could have done it with just one AI step for both results. And finally since the zap is working correctly I don’t know how to create an error to test but I will figure it out.  So thank you for the help.


@Coburn123 

You should only need 1 AI by Zapier step that can generate both counts for you.
2 INPUTS

2 OUTPUTS


I see the two input fields connected by an ‘and’.  Is there a correct way to format the prompts to distinguish the prompt for the first input  from the prompt for the second input?


@Coburn123 

You would need to post screenshots to give us context about what you are referring to.