Why the conditions are not working properly?

  • Profile Image
    adornedwithpolish
    Asked on September 17, 2017 at 03:47 PM

    Hi. On the form below I'm having a calculation issue. It is currently set up so that 3 columns from 4 different Input Tables are adding up into a 5th Input Table.

    In the 5th input table I need to have the 3 columns add up and placed into a different field. I have it setup that way using the Calculate Field condition but it's not adding up as is should.

    Please do the following on my form to see what I'm talking about:

    1. Check 1 service in Column 1 (Person #1) in any of the first four Input Tables.

    2. Please note that you will now see the correct total in the fifth Input Table (Total) in both Column 1 (Person #1) and Column 4 (Total).

    3. It also shows correctly in the second "Subtotal" field at the bottom.

    3. Now scroll back up and check an additional service but this time in Column 2 (Person #2) in any of the first four Input Tables.

    4. You will now see that while it does add up correctly in the fifth input table (Total), it does not add the new selection into the second "Subtotal" field at the bottom.

    5. If you go back up and make a 3rd selection from any of the first four input tables, the 2nd selection will now add into the total but the 3rd selection will not. It's like it's always one selection behind in the calculation.

    Please help!

  • Profile Image
    Nik_C
    Answered on September 17, 2017 at 04:32 PM

    Thank you for a detailed explanation it was very helpful. I understood the problem and I was able to replicate it. I will work on this issue to try to find the cause of it and I'll get back to you as soon as I finish.

    Thank you for your patience.

  • Profile Image
    Nik_C
    Answered on September 18, 2017 at 04:25 AM

    Thank you for your patience.

    I worked on this issue and I had to recreate the conditions for calculating person #1, #2 and #3. 

    I pretty much used each of service, checked if they are filled and calculated all for Person1, then for Person2 and for Person3.

    Here is my test form: https://form.jotformpro.com/72596673051967

    Please check if it is working for you. I tested and it is working as intended. You can check my conditions as well.

    We'll wait for your response.

    Thank you!

  • Profile Image
    adornedwithpolish
    Answered on September 18, 2017 at 11:55 PM

    Thank you for your reply. I tried deleting the conditions and setting them up again as you suggested however I am still having the same issue. Can you please take a look at my conditions and let me know if perhaps I formatted mine differently in case that is what is causing my issue. Thanks!

  • Profile Image
    ashwin_d
    Answered on September 19, 2017 at 01:27 AM

    I did check the conditions you have added in form and looks like the calculation value is not being inserted correctly. Please check the screenshot below:

    You also seems to have duplicate conditions as well. The best way I would suggest you is to clone my colleague's form and start using it. If you want to use your own form, the conditions needs to be edited. Please let us know if we can edit the condition you have added in your form and we will do the needful.

    We will wait for your response.

  • Profile Image
    adornedwithpolish
    Answered on September 19, 2017 at 06:37 PM

    I played around with it and got it to work. The issue was that in the TOTAL table, I had a 4th column where I was having the other 3 columns add up to. Once I removed that 4th column and instead totaled it into a separate number field it worked properly.

    One last thing. Despite changing the column width for the TOTAL table, the columns do not widen in mobile view so it will only display up to 2 digits in each row. For instance, instead of display 100 it will display 10.


  • Profile Image
    Kevin_G
    Answered on September 19, 2017 at 07:55 PM

    Glad to know your issue was resolved. 

    Regarding your second question, it's been moved to a different thread, we will assist you as soon as possible here: https://www.jotform.com/answers/1252272