Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Need Help to get Expression

Hi All,

I have Office , Start date, and calendar date , now I want to compare Start Date with Calendar date,

if Start date equals to the  the calendar date then I need sum(office) by Year wise.

can any one help to get the expression.

for sample data PFA.

Regards

John

1 Solution

Accepted Solutions
ramoncova06
Specialist III
Specialist III

I assume your requirement is more that just what you uploaded but, this you can use "p" for this

sum({<StartDate =p(Date)>}office)

View solution in original post

5 Replies
ramoncova06
Specialist III
Specialist III

I assume your requirement is more that just what you uploaded but, this you can use "p" for this

sum({<StartDate =p(Date)>}office)

Not applicable
Author

Hi Ramon Covarrubias.

Thanks. it works fine.

can you please explain what is the use of P(), E() functions in which situation we can use these two. functions.

is there any Performance issues with these two functions, or else any Performance improvements.

Regards

John

ramoncova06
Specialist III
Specialist III

in set analysis QV normally does not like to compare arrays of data, with the exception of manually defining the values e.g. date = {'2015-01-01','2015-02-01'}  or by using P and E, that is normally used when your list is too big manually add

performance wise there is not really an issue unless both fields being compared have millions of rows

Not applicable
Author

can you please explain me what is the meaning of

today(1)

count(1)

count(total)

Regards

John

ramoncova06
Specialist III
Specialist III

  • today(1)  is the equal to you current system time
  • I assume is count({1} field) this is to ignore all selections
  • count(total), this will give you the total of the expression, based on you current selections,
    • let say you have the following data

FieldMetric
A1
B1
C1

         if you do a sum(Metric) using the field as your dimension you will get 1 per each, though if you use sum(total Metric) you will get 3 on each line