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

how to write expression

Hello  All,

this is my expression to get  financial year ,which is working great

'FY'&year(AddYears(yearstart (ENSTEHDAT, 1, 4),-1)) &'-'&Year(yearstart (ENSTEHDAT, 1, 4)) as Year


this is what i am getting

ESTEHDAT           Year

10/29/2003           FY2003-2004

what i am looking is this

ESTEHDAT           Year

10/29/2003           FY03-04


how to get only two values from year fiels

1 Solution

Accepted Solutions
tamilarasu
Champion
Champion

Try this,

'FY'& Date(AddYears(yearstart (ENSTEHDAT, 1, 4),-1),'YY')  &'-'& Date(yearstart (ENSTEHDAT, 1, 4),'YY') as Year

View solution in original post

3 Replies
Not applicable

Hi,

try this,

'FY'&Date(AddYears(yearstart (ENSTEHDAT, 1, 4),-1),'YY') &'-'&Date(yearstart (ENSTEHDAT, 1, 4),'YY') as Year


-Joyson G

tamilarasu
Champion
Champion

Try this,

'FY'& Date(AddYears(yearstart (ENSTEHDAT, 1, 4),-1),'YY')  &'-'& Date(yearstart (ENSTEHDAT, 1, 4),'YY') as Year

susovan
Partner - Specialist
Partner - Specialist

Hi Naveen,

It might be work.

Please check this attachment.

Warm Regards,
Susovan