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

Date set analysis

Hi guys,

 

I have an expression like:

SUM({<DATE(FLOOR(SalesDate))={">=addyears(today(),-1)<today()"}>}Sales), but it's not returning back results. I guess it doesn't allow me to do something like: DATE(FLOOR(SalesDate)). I'm wondering how should I rewrite this function? 

1 Solution

Accepted Solutions
dplr-rn
Partner - Master III
Partner - Master III

Let take this step  by step

Your set syntax is wrong change to

SalesDate={">=$(=addyears(today(),-1))<$(=today())"}

on the floor part

i actually havent tried DATE(FLOOR(SalesDate)) in the set expression before. i would recommend doing this step in the script.

Is your salesdate a timestamp? if not you dont need the floor function

View solution in original post

1 Reply
dplr-rn
Partner - Master III
Partner - Master III

Let take this step  by step

Your set syntax is wrong change to

SalesDate={">=$(=addyears(today(),-1))<$(=today())"}

on the floor part

i actually havent tried DATE(FLOOR(SalesDate)) in the set expression before. i would recommend doing this step in the script.

Is your salesdate a timestamp? if not you dont need the floor function