8 Replies Latest reply on Dec 6, 2018 7:07 PM by Faiz MH

    Case Statement if having same name

    Faiz MH

      Hi guys,


      I have the following case statement which basically showing Equipment name and its capacity data (pulled from a Sql database) as shown:



          WHEN "X1" THEN 100

          WHEN "X2" THEN 100

          WHEN "X3" THEN 100

          WHEN "X4" THEN 200

          WHEN "X5" THEN 300

          WHEN "X6  THEN 400

      ELSE 0



      However, recently I noticed that there is another Equipment also named as X4 in the database but having higher capacity at 350. I would like to ask in this situation how can I work around with the CASE statement as now there are two X4 but at different capacity. If it's not possible, kindly recommend a way.


      Thank you.