Skip to main content
Announcements
See why Qlik is a Leader in the 2024 Gartner® Magic Quadrant™ for Analytics & BI Platforms. Download Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Help with Minimum for Field ignoring selection

Hi Qlikview Experts,

Really appreciate your help in advance - been struggling with this for quite some time and it I may just be approaching this the wrong way.

I need to find out the Min date associated with a Field (ID) while Ignoring the Selection Currently In Place.

Example

Current Selection:  Load File Field = 'Week of April 15.xls'

Resulting Straight Table:

Load DateLoad FileID NumberDesired First Load Date
15-AprWeek of April 15.xlsABC-1231-Apr
15-AprWeek of April 15.xlsDDD-44414-Apr
14-AprWeek of April 15.xlsDDD-44414-Apr

Original Set of Data

Load DateLoad FileID Number
15-AprWeek of April 15.xlsABC-123
1-AprWeek of April 1.xlsABC-123
4-AprWeek of April 1.xlsABC-123
15-AprWeek of April 15.xlsDDD-444
14-AprWeek of April 15.xlsDDD-444
7-AprWeek of April 7.xlsEEE-000

The 'First Load Date' is the field I'm struggling with.  This should return the First Load Date for each ID Number.  What I've tried already:

=aggr(min( {1} [Load Date], [ID Number]) -- this returns 1-Apr for everything (which makes sense)

=min([Load Date]) - this returns the minimum for the ID Number of the current selection (In the example above it would return 15-Apr for ABC-123 and Apr-14 for DDD-444)

Would appreciate your thoughts, I always struggle communicating these problems. 

1 Solution

Accepted Solutions
swuehl
MVP
MVP

Maybe like this?

=aggr(min({1} Total<IDNumber> LoadDate),IDNumber,LoadDate)

View solution in original post

4 Replies
Not applicable
Author

May you share sample. It is always easier to fight having model and sample data ....

Not applicable
Author

Thanks for the quick response Dariusz, please see the attached file.

swuehl
MVP
MVP

Maybe like this?

=aggr(min({1} Total<IDNumber> LoadDate),IDNumber,LoadDate)

Not applicable
Author

Amazing!  This site never ceases to wow me.

Hopefully someone else down the line will have the same question.

Appreciate everyones effort (especially you swuehl)