Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
mahitham
Creator II
Creator II

Need help on IF Logic

Hi Experts,

Can any one please help me to replicate the below logic into qlik

=If(OR(ISBLANK(Startdate ), ISBLANK(Enddate)),"",

     IF(AND(Type="New",Status="Completed"),NETWRORKDAYS(Startdate,Enddate), "")

  )


Thanks in advance.


1 Solution

Accepted Solutions
agigliotti
Partner - Champion
Partner - Champion

take a look at https://help.qlik.com/en-US/sense/April2018/Subsystems/Hub/Content/Scripting/DateAndTimeFunctions/ne...

you can use someting like this:

if( len(trim(Startdate)) = 0 or len(trim(Enddate)) = 0, '',

networkdays( Startdate, Enddate )

) as TimeTaken


Hope it helps.

View solution in original post

3 Replies
agigliotti
Partner - Champion
Partner - Champion

take a look at https://help.qlik.com/en-US/sense/April2018/Subsystems/Hub/Content/Scripting/DateAndTimeFunctions/ne...

you can use someting like this:

if( len(trim(Startdate)) = 0 or len(trim(Enddate)) = 0, '',

networkdays( Startdate, Enddate )

) as TimeTaken


Hope it helps.

arulsettu
Master III
Master III

may be like this in qlik

if(isnull(Startdate) or isnull(Enddate),''

,if(Type='New' and Status='Completed',

NETWORKDAYS(Startdate, Enddate))

avkeep01
Partner - Specialist
Partner - Specialist

Hi Mahitha,

you can try:

IF(Startdate>0 OR Enddate >0, IF(Type = 'New' AND Status  = 'Completed',NETWORKDAYS(Startdate,Enddate)))