1 Reply Latest reply: Nov 24, 2014 1:15 PM by Jonathan Poole RSS

    Added a Field from my Data Set as an expression, but having trouble filtering out certain variables

    Myles Holland

      Hello all,

       

      I was hoping someone might be able to help me with this script:

       

      if(Num( DISTINCT
      {<
      [Project Status]-={'PROJECT AWARDED', 'COMPLETED', 'PROJECT CANCELLED', 'ON HOLD'}
      >}
      1)=1,
      [Estimated Provject Value],'$###,###.')

       

      Basically, I am adding this expression because I needed a field that displayed the projected value of a project. This is a currency value, which is why I added it as an expression to allow me to format as I saw fit. The filtering seems to be working, but the values are displaying as "-" in my table.

       

      Any insights into what I may be doing wrong here?

       

      Regards,

       

      Myles

       

        • Re: Added a Field from my Data Set as an expression, but having trouble filtering out certain variables
          Jonathan Poole

          The expression  syntax is wrong . The issue is that its not obvious what you are trying to do  


          Here are a couple of guessed alternatives. Note that i'm summing the Estimated Project Value and i'm not sure if that is what you want.

           


          num(

               sum(    {<[Project Status]-={'PROJECT AWARDED', 'COMPLETED', 'PROJECT CANCELLED', 'ON HOLD'}>}

                    [Estimated Provject Value] )


              ,'$###,###.')


          or


          num(

               sum(

                    if( NOT(  match( [Project Status], 'PROJECT AWARDED','COMPLETED', 'PROJECT CANCELLED', 'ON HOLD') ) , [Estimated Provject Value] )


              ,'$###,###.')