Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Modernize Your QlikView Deployment webinar, Nov. 3rd. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Master II
Master II

Expression meaning

What is the meaning of the below expression meaning?

=year(today())-$1

Thanks in advance.

1 Solution

Accepted Solutions
Highlighted
Champion III
Champion III

Looks like a variable with parameter.  If you have a variable vYear defined as

year(today())-$1 

You can use it in a text box

=$(vYear(5))

and it will return 2010

Edit: see attached

View solution in original post

10 Replies
Highlighted

is this full expression?

Where are you using it?

Highlighted
Master II
Master II

Hi Robert_Mika,

This is full expression. This was used in a variable.

Highlighted

Does it work?

Because with this syntax it will throw error

Highlighted
Master II
Master II

Hi Robert_Mika,

Yes. This is used in an existing application.

Highlighted

What's the result ?

Highlighted
Master II
Master II

Just it is showing '-'.

Highlighted
Champion III
Champion III

Looks like a variable with parameter.  If you have a variable vYear defined as

year(today())-$1 

You can use it in a text box

=$(vYear(5))

and it will return 2010

Edit: see attached

View solution in original post

Highlighted
Not applicable

Hi

This is an expression. First part of the expression = year(today()) will give the current year.

Second pert $1 is variable with parameter. before use that first you have to create variable.

ex : eyear = year(today()) - $1

Please check the example I found :

eDeparturePerformed_VarUnit = Sum(# Departure Performed ) / 1$


1. 1st Expression - No of Flight will be = $(eDeparturePerformed_VarUnit (1))

2. 2nd Expression - No of Flights ( Thousand ) = $(eDeparturePerformed_VarUnit (1000))

2. 3rd Expression - No of Flights ( Millions ) = $(eDeparturePerformed_VarUnit (1000000))

Highlighted
Master II
Master II

Hi mov,

Thank you so much.