FUNCTIONS DAYNAME() AND MONTHNAME() RETURN RESULTS IN ENGLISH ONLY
Starting DB2 Version 9.7, DB2 has provided mothnname under schema SYSIBM and SYSFUN. Since the default value of current path special register is "SYSIBM","SYSFUN","SYSPROC","SYSIBMADM", sysibm function are invoked for default current path. The sysibm.MONTHNAME function returns a character string containing the name of the month (for example, January) for the month portion of expression, based on value of the special register CURRENT LOCALE LC_TIME.". The initial or default value of CURRENT LOCALE LC_TIME is "en_US" for English (United States). Which mean sysibm.monthname returns dayname/monthname in English.
Application can specify the desired value of CURRENT LOCALE LC_TIME to get the value of monthname/dayname in the desired locale or change the current path value to invoke sysfun function.
If you do not want to modify application, DB2 added new funcationality to customize an application environment using the connect procedureon server. Here is the link
Monthname saclar function:
MONTHNAME scalar function
This is 'working as per design'. You can update the application env or use connect_proc to change the desired value of special registers.
NOTE : In DB2 version 9.5 MONTHNAME scalar function exist under schema SYSFUN.
This issue was addressed through APAR IZ57412, first fixed in version 9.5 FixPak 5.
Bottomline is there is behaviour change starting from DB2 version 9.7 for this issue.
More support for:
DB2 for Linux, UNIX and Windows
OTHER - Uncategorised
Software version: 9.7, 9.8, 10.1, 10.5
Operating system(s): AIX, HP-UX, Linux, Solaris, Windows
Reference #: 1642247
Modified date: 18 November 2015