Dear Community,
I want to make a string containing the week of a date,
is it possible to do so with Format Patterns?
Of course I could compose as a string, but I like the tight way doing it with Format Patterns.
Thanks and best regards,
Names Default To Here( 1 );
Print( Format( Today(), "Format Pattern", "<YYYY>_<MM>" ) );
// Format Patern does not recognize WW
Print( Format( Today(), "Format Pattern", "<YYYY>_<WW>" ) );
// this works
Print( Char( Year( Today() ) ) || "_" || Right( "0" || Char( Week Of Year( Today() ) ), 2 ) );
Names Default To Here( 1 );
Print( Format( Today(), "Format Pattern", "<YYYY>_<MM>" ) );
// Format Patern does not recognize WW
Print( Format( Today(), "Format Pattern", "<YYYY>_<WW1>" ) );
"2024_08"
"2024_32"
Names Default To Here( 1 );
Print( Format( Today(), "Format Pattern", "<YYYY>_<MM>" ) );
// Format Patern does not recognize WW
Print( Format( Today(), "Format Pattern", "<YYYY>_<WW1>" ) );
"2024_08"
"2024_32"
great - Thanks!
Iso week (ww) is also very helpful. Keep in mind that it can just be used in combination with ISO year (yyyy).
Unfortunately, there is an issue in Graph Builder with this time format - year 2023 is missing:
https://community.jmp.com/t5/Discussions/Time-binning-how-to-change-the-Tick-labels/m-p/762929/highl...