# New to Qlik Sense

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

Announcements
Become an analytics expert with Qlik's new 15 week course: Applied Data Analytics using Qlik Sense. READ MORE
cancel
Showing results for
Did you mean:
Partner

## This year and last year

I have this expression:

if(Week(today())<19,

Sum({<År0101={'\$(=year(today()-1))'},Framskrivningsalternativ={"Faktisk"}>}Folkemengde_fram_SSB),

Sum({<År0101={'\$(=year(today()))'},Framskrivningsalternativ={"Faktisk"}>}Folkemengde_fram_SSB))

The first conditional expression is supposed to retrieve the sum for last  year. The second expression is supposed to retrieve the sum from the current year.

The first expression does not work correctly. Consequently, both expressions give me the same result (from the current year).

1 Solution

Accepted Solutions
Champion

Hi,

try this:

if(Week(today())<19,

Sum({<År0101={'\$(=year(today()))'},Framskrivningsalternativ={"Faktisk"}>}Folkemengde_fram_SSB))

Champion

Hi,

try this:

if(Week(today())<19,