Skip to main content
Announcements
Qlik Connect 2025: 3 days of full immersion in data, analytics, and AI. May 13-15 | Orlando, FL: Learn More
cancel
Showing results for 
Search instead for 
Did you mean: 
master_student
Creator III
Creator III

condition

Hello

I need to set a condition in my expression to display the time only if it is >13:00:00 and <14:00:00

If(time(DATE_DEB)>'13:00:00', and time(DATE_DEB)>'13:00:00', '')

DATE_DEB has this format : 12/01/2016 12:32:55

any idea please

11 Replies
marcus_sommer

To display time as dimension within the chart didn't meant that you couldn't create hour/minute and so on and maybe some flags within the script and to use these fields within the chart-expressions.

- Marcus

miguelbraga
Partner - Specialist III
Partner - Specialist III

If so make this change:

Table:

LOAD *,

               Flag_Greater13 * Flag_Lesser14 as Flag;

LOAD *,

               if(

                    time( timestamp(DATE_DEB,'DD/MM/YYYY hh:mm:ss') )

                    >

                   time( timestamp(date(floor(DATE_DEB) ,'DD/MM/YYYY') + time(MakeTime(13),'hh:mm:ss'),'DD/MM/YYYY hh:mm:ss'),

               1, 0) ) as Flag_Greater13,

               if(

                    time( timestamp(DATE_DEB,'DD/MM/YYYY hh:mm:ss') )

                   <

                    time( timestamp(date(floor(DATE_DEB) ,'DD/MM/YYYY') + time(MakeTime(14),'hh:mm:ss'),'DD/MM/YYYY hh:mm:ss'),

                1, 0) ) as Flag_Lesser14;

LOAD *

FROM [your connection to your database goes here];