Skip to main content
Announcements
Global Transformation Awards! Applications are now open. Submit Entry
cancel
Showing results for 
Search instead for 
Did you mean: 
Kushal_Chawda

Load order sort with Aggr

Hi All,

I have attached the sample data and the QVW file.

In QVW file there is one straight table created in which there is one expression which calculates the status "New" or "Repeated".

Now, my straight table dimensions are sorted as required from back end itself (check the order by in script).

Straight table works fine as expected. What I want is that, I want to show the count of "Repeated" status in text object.

If you export the straight table in excel, count of the repeated status is 1306, which I want to show in text object.

Note: User can select anything from dimension and count should work dynamically based on selection


I tried the same expression using Aggr, but seems to be wrong. May be it's easy but get stuck.

1 Solution

Accepted Solutions
sunny_talwar

This seems to be working

=Sum(Aggr(if(START_DATE_DEFECT1-Below(TOTAL START_DATE_DEFECT1,1,1)>731 or Below(TOTAL Repeated_Defect1,1,1)<>Repeated_Defect1,0,1), GBU_D1, BU_D1, COMPLAINT_NO_D1, START_DATE_DEFECT1, Facility_D1, COMPLAINT_DATE_D1, START_DATE_DEFECT1, BU_DEFECT1, DEFECT_LOCATION1, Repeated_Defect1))

View solution in original post

11 Replies
sunny_talwar

May be this

=Count(DISTINCT Aggr(if(START_DATE_DEFECT1-Below(TOTAL START_DATE_DEFECT1,1,1)>731 or Below(TOTAL Repeated_Defect1,1,1)<>Repeated_Defect1,0,COMPLAINT_NO_D1&COMPLAINT_DATE_D1), COMPLAINT_NO_D1, COMPLAINT_DATE_D1))

Anil_Babu_Samineni

I have one funny solution with me? I assume, You need some aggregation with Complaint No & Date and Count? But, I am not done that my self. May be Sunny has some answer

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
Anil_Babu_Samineni

Funny STAR. Nice Boss

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
Kushal_Chawda
Author

I sunny, thanks for your response, but when I select one GBU="BCS", it's not working

Anil_Babu_Samineni

When you select GBS you want to show 144 ???

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
Kushal_Chawda
Author

Yes correct

sunny_talwar

Checking

sunny_talwar

This seems to be working

=Sum(Aggr(if(START_DATE_DEFECT1-Below(TOTAL START_DATE_DEFECT1,1,1)>731 or Below(TOTAL Repeated_Defect1,1,1)<>Repeated_Defect1,0,1), GBU_D1, BU_D1, COMPLAINT_NO_D1, START_DATE_DEFECT1, Facility_D1, COMPLAINT_DATE_D1, START_DATE_DEFECT1, BU_DEFECT1, DEFECT_LOCATION1, Repeated_Defect1))

Kushal_Chawda
Author

Great man.