Java Snippet

@Victor_Marguti there are several ways to install extensions even if you cannot do it thru a regular update site:

https://docs.knime.com/latest/analytics_platform_installation_guide/index.html#_adding_local_update_sites

5 Likes

It had been a while since I had to create math if statements in base nodes only. For some reason the Math node if statements refused to calculate at several points even though there were no errors or syntax issuesā€¦ Trying to work without the Column Expressions node is like having both of my hands tied behind my back. Highly recommend downloading that one if possible.

1 Like

Hello!

This workflow is perfect, in terms of performance it was almost imperceptible!

1 Like

Awesome! Glad it worked for you. Please mark the workflow as the solution so it is easier to find in future forum searches when you get the chance.

I am always curious in the run time difference between native KNIME loops vs running code in Python, R, etc. I always prefer the KNIME approach when the native functionality exists to pull it off.

2 Likes

Hey bro!

In order to validate and test possible scenarios, I came across this situationā€¦

Order 1 = 250 QTY gave a result of 252
Order 2 = 6 QTY gave a result of 5

It seems that the flow is lost when there are no decimal numbers (10, 20, 30ā€¦ etc)

I tried to create a scenario where order 1 had a stock of 151 QTY (A1335C) and another scenario where order is 6 and had stock of 4, 7 and 9 QTY. In both scenarios, the sum was lost.

Can you help me?

Question - Order.knwf (2.8 MB)

1 Like

Question - Order.knwf (3.1 MB)

Try running this one through your full data. I added a test at the end that should help identify any calc issues.