#274 format-date() with 2-digit year doesn't work

v8.2
closed
5
2012-10-08
2004-12-23
Michael Kay
No

Attempting to output a two-digit year using
format-date() with a picture such as [Y01,2-2] doesn't
work. The year is output as four digits.

Source fix: at line 330 of
net.sf.saxon.functions.FormatDate, change

if (format.charAt(0) == 'Y') {

to

if (component.charAt(0) == 'Y') {

The error is in 8.2 and probably in all previous releases.

Discussion