Date: current quarter
Posted: Wed Jul 06, 2016 1:50 am
Hi
I want to generate a string with the current ended quarter.
these codes will do it:
%date=@date
genr adummy=@before(%date)
smpl if adummy<1
genr adummy= na
string aadate=adummy.@last
this gives me "2016Q2", which is what i want.
but, is there a more efficient way?
in contrast,
string aadate2=@datestr(@now-1, "yyyy:q")
yields "2016:3"
Thomas
I want to generate a string with the current ended quarter.
these codes will do it:
%date=@date
genr adummy=@before(%date)
smpl if adummy<1
genr adummy= na
string aadate=adummy.@last
this gives me "2016Q2", which is what i want.
but, is there a more efficient way?
in contrast,
string aadate2=@datestr(@now-1, "yyyy:q")
yields "2016:3"
Thomas