Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

vardhancse
Not applicable

Create a new field

Hi All,

I have a requirement is that,

one field: Emp joined date (MM/DD/YYYY)

Now I want to create a field :

That I should get the count in months i.e. (Today() - (Emp joiined date))

I am using the above mentioned expression, but was unable to get the data. Can any one please help me out in getting the same.

Thanks in advance

1 Solution

Accepted Solutions
dvasseur
Not applicable

Re: Create a new field

And this ?

Year(Today())*12+Month(Today()) - (Year([Emp joined date])*12+Month([Emp joined date]))

4 Replies
mayilvahanan
Not applicable

Re: Create a new field

HI

Try like this

Floor(Today()) - Floor([Emp joined date])  // Its give days not in month..



vardhancse
Not applicable

Re: Create a new field

Hi thanks for your reply/answer,

My requirement is that I want to display in months rather than in days.

Can you please help me out

dvasseur
Not applicable

Re: Create a new field

And this ?

Year(Today())*12+Month(Today()) - (Year([Emp joined date])*12+Month([Emp joined date]))

vardhancse
Not applicable

Re: Create a new field

Hi David,

It was my requirement.

Thanks for your support.