No announcement yet.

formula to run based on numbers

  • Filter
  • Time
  • Show
Clear All
new posts

  • formula to run based on numbers

    i have the following situation...

    Account entity has 2 feilds: bot1 and bot2. i need a formula to make a workflow that if bot1 drops below '0' it creates a quote, and then create additional quotes based off of bot2

    So lets say i have an account who has 5 in bot1 and 5 in bot2. then i change bot1 to -1
    it would create a quote. then would not create another quote until bot1 reached the number in bot2 each time. sequintially.

    so each time bot1 passed the number in bot2 it would make a quote

  • #2
    You can set in condition formula something like this

    entity\isAttributeChanged('bot1') && (bot1 < bot2) && entity\attributeFetched('bot1') == entity\attributeFetched('bot2')

    in action you could create a quote


    • #3
      that works, but not how i need it to...

      STEP1: lets say bot1 is at value 5. bot2 has a value of 5 which is my control field for step 2. when i change bot1 to -1 below value 0, it will trigger a quote.
      STEP 2: then lets say i change bot1 to value -3, it wont trigger another quote until bot1 goes past the set number in bot2. so kind of like for every 5, make quote.


      • #4
        For this, I think, you need to add one boolean additional field in Entity Manager and set it with workflow or with formula. You neednthis field for flaging that bot 1 goes past bot 2


        • #5
          ok thanks! that seems to work for now!