6 Replies Latest reply: Nov 29, 2017 4:25 AM by Jonathan Dienst RSS

    Static expression

    Patrick routier


      I need to have a static expression, mean not depending to any filters selected.

      In my example attached, the chart not change if no weeks selected or I flast week (46) is selected. this is a good behavior, but If I select an other week the chart becomes blank and my target is that I would like to show always the last week (week 46 in my example).


      I hope that I was enough clear.

      thank you in advance for your help.



        • Re: Static expression
          Jonathan Dienst

          Use {1} as rge base set in a set expression. This ignores all selections. Like this:


          =Sum({1} Amount)               // ignore all selections


          =Sum({1<Week = {"$(=Max(Week))"}>} Amount)  // last week or last selected week


          =Sum({1<Week = {"$(=Max({1} Week))"}>} Amount)  // last week

            • Re: Static expression
              Patrick routier

              thank you for your quick answer.

              • Re: Static expression
                Patrick routier

                One more question, it's works as it is ( =count({1<Week={$(vPreviousWeek)}>}Lot) ) with one or more static 'field'.

                but if I would like to have 1 static field (without any action in the amount), like Week in this example but other filters potentially selected able to modified the result of the expression.


                I don't know if I'm clear... in my example the Week is frozen, but I want that if I select a Site, the amount must be impacted.

                  • Re: Static expression
                    Jonathan Dienst

                    I am a little confused

                    original post >> mean not depending to any filters selected


                    now >> the amount must be impacted


                    So which is it? {1<...>} will override the other selections as you requested in your original post. Or if you want to respect selections use {$<...>}. If you want to ignore slections in all fields except one or two, then use


                    {1<Field1 = $::Field1, ....>}

                      • Re: Static expression
                        Patrick routier

                        Hello Jonathan ,

                        Sorry to make you confused.

                        You're right, my request evoluted. now in the same expression, I would like to freeze 1 field (Week in my example) but I want the chart potentially modified when the user select 1 site or 1 people (see my attached example )

                        Expression used in the chart are:

                        = count({1<Week={$(vMaxWeek)}>}Lot)




                        Thank you in advance.