Skip to main content

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
NEW webinar Dec. 7th: 2023 Outlook, A Pivotal Year for Data Integration SIGN ME UP!
cancel
Showing results for 
Search instead for 
Did you mean: 
ksharpes
Creator
Creator

Help with Aggregation Expression

Hello,

The following expression works, however I wish to change the date based on data from another field.

=aggr(Maxstring({<[Reporting Date]={'31/12/2019'}>} Class),Item_ID)

The field i want the date from is [Restocked Date] this will be formatted as either

1-No Sales Data, 2-Continued, 3-31/12/2019 (Various dates).

The below expression also works and separates the date part.

=if(Len([Restocked Date])=12,MID([Restocked Date],3,len([Restocked Date])-2),'')

So i am attempting to use the following expression however it will not work.

=aggr(Maxstring({<[Reporting Date]={'$(=if(Len([Restocked Date])=12,MID([Restocked Date],3,len([Restocked Date])-2),''))'}>} Class),Item_ID)

Any assistance would be appreciated

 

2 Replies
kashyap311996101
Partner - Specialist
Partner - Specialist

Hi

Try this

aggr(Maxstring({<[Reporting Date]={"$(=if(Len([Restocked Date])=12,MID([Restocked Date],3,len([Restocked Date])-2),''))"}>} Class),Item_ID)

Hope this helps

Thanks

Thanks and Regards
Kashyap.R
ksharpes
Creator
Creator
Author

No joy unfortunately.