Skip to main content

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
An issue has been identified on Qlik Cloud hub, please visit our Status Update Page for details: GET THE LATEST
cancel
Showing results for 
Search instead for 
Did you mean: 
joshi_qlikview
Creator
Creator

contract term Default to 3 Years

Hi Guru's,

I have contract Term,Contract term Details fields

if contract term =3 years,in contract term details -Year 1 of 3

                                                    Year 2 of 3

                                                    year 3 of 3  like that

in contract term i have fields Like One "Off","Other","perpetual","TBD"

but i want to make 3 years as Default contract year if any field found like  "Other","perpetual","TBD"

how to achieve this.

please find the sample application as attached

Thanks in advance

1 Solution

Accepted Solutions
CELAMBARASAN
Partner - Champion
Partner - Champion

May be this would help you

If(WildMatch([Contract Term], '*Months*'), Ceil(KeepChar([Contract Term],0123456789)/12), If(Num(KeepChar([Contract Term],0123456789)), Num(KeepChar([Contract Term],0123456789)),3))  as MaxNum

View solution in original post

6 Replies
sunilkumarqv
Specialist II
Specialist II

Write it in script

in preceding load

Load *,

if(match([Contract term], 'Other','perpetual','TBD'),If([Contract term details],'3 year',Contract term))  as [Contract term]

LOad * from data source


joshi_qlikview
Creator
Creator
Author

can u do it in sample ,iam un able to achieve result

Thanks in advance. take application as binary it will work

Thanks in advance

CELAMBARASAN
Partner - Champion
Partner - Champion

Change this if Statement

If(WildMatch([Contract Term], '*Months*'), Ceil(KeepChar([Contract Term],0123456789)/12), If(MixMatch([Contract Term], 'Other','perpetual','TBD'),3, Num(KeepChar([Contract Term],0123456789))))  as MaxNum,   

joshi_qlikview
Creator
Creator
Author

hi celambarasan,

thanks for your time

other than Other','perpetual','TBD  i have blanks in contract Term

how  to pull those 

thanks inadvance

joshi_qlikview
Creator
Creator
Author

for blank contract terms also default i would show 3  Year

CELAMBARASAN
Partner - Champion
Partner - Champion

May be this would help you

If(WildMatch([Contract Term], '*Months*'), Ceil(KeepChar([Contract Term],0123456789)/12), If(Num(KeepChar([Contract Term],0123456789)), Num(KeepChar([Contract Term],0123456789)),3))  as MaxNum