4 Replies Latest reply: Mar 20, 2017 9:17 AM by Charlie Leo RSS

    can anyone write in Setanalysis

    Charlie Leo

      count(if(AgentOrDist='A',AgentID))/count(TOTAL <[Zone],[Region],[Cluster],[JC]> if(AgentOrDist='A',AgentID))

       

      Hello everyone ,

       

      Help me write in setanalysis,

       

      Thanks In Advance

        • Re: can anyone write in Setanalysis
          Anushree Shetty

          Try This:

          =count({<AgentOrDist={'A'}>}AgentID)/count(TOTAL <[Zone],[Region],[Cluster],[JC]> {<AgentOrDist={'A'}>}AgentID)

            • Re: can anyone write in Setanalysis
              Charlie Leo

              Anychance we can right this in setanalysis

               

              if(vJCFactor=1,

              COUNT(DISTINCT IF(aggr((sum(if(TranDt>=$(vFromDate) AND TranTyp='CO',TranAmt))/SUM(AGGR(if(DsbrDate>=$(vFromDate) and DsbrDate<=Today

                AND DsbrDate >= MonthStart(min(TranDt)) and DsbrDate <= MonthEnd(max(TranDt)), SUM(DisbrAmt)),DsbrDate,JC))),JC)>=.5,JC)),

               

               

              if(vJCFactor=2,

              COUNT(DISTINCT IF(aggr

              (SUM(if(TranTyp='CB' AND TranDt>=$(vFromDate), TranAmt))/

              SUM(AGGR(if(DemandDate>=$(vFromDate) and DemandDate<=Today

                          AND DemandDate >= MonthStart(min(TranDt)) and DemandDate <= MonthEnd(max(TranDt)), SUM(DemandAmt)),DemandDate,JC)),JC)

              >=.75,JC)),

               

               

              if(vJCFactor=3,

              COUNT(DISTINCT IF(aggr(count(DISTINCT if($(AgntMonthlyComm)>=2500 AND AgentOrDist='A',AgentID))

                /count(DISTINCT if(AgentOrDist='A',AgentID)),JC)>=.4,JC)),

               

               

              if(vJCFactor=4,

              COUNT(DISTINCT IF(aggr(sum(if(TranDt>=$(vFromDate) AND TranTyp='DR',TranAmt))/$(vTotalTranAmt),JC)>=.2,JC)),

               

               

              COUNT(DISTINCT IF(aggr(COUNT(DISTINCT IF(Status='A' and AgentOrDist= 'A',AgentID))

                /COUNT(DISTINCT IF(AgentOrDist= 'A',AgentID)),JC)>=.5,JC))))))

            • Re: can anyone write in Setanalysis
              Carlos Monroy

              Hi Charlie,


              Try:


              if( AgentOrDist = 'A', count(AgentID)/Count(Total <[Zone],[Region],[Cluster],[JC]> AgentID))


              or


              count({<AgentOrDist = {'A'}>}AgentID)/count(Total <[Zone],[Region],[Cluster],[JC]> {<AgentOrDist = {'A'}>}AgentID)



               

              Hope it helps,

              Carlos M