Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I work in a university and I want to change the calendar year to be an academic year - so rather than having week 1 start in January I want it to start in August. How do I offset the weeks so that week 1 starts then?
Thanks
Alison
Something like this will convert Years to FiscalYears and Months to FiscalMonths. Also includes 'CalendarMonths' so you can keep track .
LOAD
Date,
if( Month(Date)>=8, Year(Date), Year(Date) -1) as FiscalYear,
if( Month(Date)>=8, Month(Date)-7,Month(Date)+4) as FiscalMonthNumber,
if( Month(Date)>=8, Year(Date), Year(Date) -1) & ' - ' & if( Month(Date)>=8, Month(Date)-7,Month(Date)+4) as FiscalYearMonth,
Year(Date) & ' - ' & Month(Date) as CalendarYearMonth,
Sales
FROM
(txt, codepage is 1252, embedded labels, delimiter is ',', msq);
Something like this will convert Years to FiscalYears and Months to FiscalMonths. Also includes 'CalendarMonths' so you can keep track .
LOAD
Date,
if( Month(Date)>=8, Year(Date), Year(Date) -1) as FiscalYear,
if( Month(Date)>=8, Month(Date)-7,Month(Date)+4) as FiscalMonthNumber,
if( Month(Date)>=8, Year(Date), Year(Date) -1) & ' - ' & if( Month(Date)>=8, Month(Date)-7,Month(Date)+4) as FiscalYearMonth,
Year(Date) & ' - ' & Month(Date) as CalendarYearMonth,
Sales
FROM
(txt, codepage is 1252, embedded labels, delimiter is ',', msq);