Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hey,
In my script i am writing :
subfield(YearStart(floor(CreateDate) , 0 , 11) , '-' , 1) + 1 as [Fiscal Year] ;
Now let say i have values of Create Date as:
01-01-2015 , 14-04-2015 , 08-011-2015.
THen for every date above , it will give same result i.e 01-011-2015 and fiscal year as 2016.
ISn't this wrong??
THanks
If you want to calculate fiscal years perhaps this blog post helps: Fiscal Year
Hi
Works for me (except replacing the SubField with Year):
LOAD CrDate,
YearStart(CrDate, 0, 11) As YS,
Year(YearStart(CrDate, 0, 11)) As YY
Inline
[
CrDate
01-01-2015
14-04-2015
08-11-2015
];
HTH
Jonathan
Hey,
THankx but my doubt was:
LEt say date field as in ur case is:
01-01-2015 , then YS would be 01-11-2014 or 01-11-2015 ?? becoz as per syntax of YearStart() , if shift = 0 then then date year is taken with month as indicated. Plz clear.
thanks