Hi,
Could you please assist. Currently using BO version 4.1 SP6
I have a task of creating a Year to LastMonthEnd filter for both current & previous year. Our financial year starts from 1st Sept. I'm trying to avoid hardcoding the date in the filter but to make it more dynamic.
DATE Between '2016-09-01 00:00:00.000' AND convert(varchar(10),dateadd(dd,-(day(dateadd(mm,-12,getdate()))-1),dateadd(mm,-12,getdate()-1)),102) + ' 23:59:59.000'
DATE Between '2017-09-01 00:00:00.000' AND convert(varchar(10),dateadd(dd,-(day(getdate())),getdate() ),102)+ ' 23:59:59:999'
I would appreciate your help on this.
Thanks in advance.
Could you please assist. Currently using BO version 4.1 SP6
I have a task of creating a Year to LastMonthEnd filter for both current & previous year. Our financial year starts from 1st Sept. I'm trying to avoid hardcoding the date in the filter but to make it more dynamic.
DATE Between '2016-09-01 00:00:00.000' AND convert(varchar(10),dateadd(dd,-(day(dateadd(mm,-12,getdate()))-1),dateadd(mm,-12,getdate()-1)),102) + ' 23:59:59.000'
DATE Between '2017-09-01 00:00:00.000' AND convert(varchar(10),dateadd(dd,-(day(getdate())),getdate() ),102)+ ' 23:59:59:999'
I would appreciate your help on this.
Thanks in advance.