Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Qlik Analytics Tour 2020 Online. Begins August 10th. Register Today
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Specialist
Specialist

Error in calculated dimension

Hi all

I have a mistery problem in a pivot table

Capture.PNG

The formulas are the same as the field names, and when I try to use "min(requesttime)" it throw an error. I think that the result of this dimension must to be at least the same of the previous column (later I will try to get the real min of each key)

Anyone can help me?

Thanks

1 Solution

Accepted Solutions
Highlighted
MVP
MVP

Re: Error in calculated dimension

your expression seems wrong

aggr(min(requesttime),Key)

View solution in original post

19 Replies
Highlighted
Contributor II
Contributor II

Re: Error in calculated dimension

Hi Jose,

Try using =only(min(requesttime))

Thanks

Harshitha

Highlighted
MVP & Luminary
MVP & Luminary

Re: Error in calculated dimension

Hi,

Just try Minstring() see if the field is in text format or not?

Regards,

Kaushik Solanki

Regards,
Kaushik
If reply is satisfactory, please "Like" the post.
If reply is solution, please mark as "Correct".
Highlighted
MVP
MVP

Re: Error in calculated dimension

Perhaps something lile

=min(Aggr(requesttime, dim1, dim2, ...))

Where dim1, dim2, ... are the other dimensions for the pivot table.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Highlighted
Specialist
Specialist

Re: Error in calculated dimension

Hi,

Is in num format, because I have used min(requesttime) in a label and it works.

Highlighted
Specialist
Specialist

Re: Error in calculated dimension

Hi,

But I only want the min resquesttime, I don't need the other dimensions

Highlighted
MVP
MVP

Re: Error in calculated dimension

The dimensions in the aggr() give the context for the minimum time. The context comes from the dimensions when the min() is a chart expression, but a calculated dimension does not get that same context.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Highlighted
MVP & Luminary
MVP & Luminary

Re: Error in calculated dimension

Hey you can not use the normal aggregation functions in dimension without the advanced aggregation function.

If you want to just get a minimum value then use it in expression instead of dimension.

To use in dimension you can try as below.

Aggr(Min(requesttime),Dim1)


Regards,

Kaushik Solanki

Regards,
Kaushik
If reply is satisfactory, please "Like" the post.
If reply is solution, please mark as "Correct".
Highlighted
Specialist
Specialist

Re: Error in calculated dimension

If I put this expresion "Aggr(min(requesttime),Dim1)" this will return an array, isn't it? I need only a one single value.

Highlighted
Specialist
Specialist

Re: Error in calculated dimension

Is still don't working

Capture.PNG

I think, I need to find a workaround and try to do it in the script