I would like to assign each weekly report a sequential number based on the week it is produced (which will be generated based on parameters of beginning and end of the week, as there may be slight variation based on holidays). Our fiscal year begins June 1st, so it makes sense for that to be report 01.
Is there anyway to reset the counter based on the date? I thought I could use some sort of WEEK function, but this doesn't seem available in Base.
Cheers
[Solved] Changing Counter Start Value
-
- Posts: 24
- Joined: Sat Jul 14, 2012 6:09 am
[Solved] Changing Counter Start Value
Last edited by One Big Yawn on Sat Aug 11, 2012 3:15 am, edited 1 time in total.
LibreOffice 3.5, MySQL 5.5, Windows 7
Re: Changing Counter Start Value
Just a simple approach might be: populate a table with from/to dates and the week number. Use in the query the current_date to find the correct report/week number.
It's Microsoft marketing that tells you computers are qualified for non-technicians
W11 22H2 (build 22621), LO 7.4.2.3(x64)
W11 22H2 (build 22621), LO 7.4.2.3(x64)