Determine the name of a specified month in a specified language.
char *dbmonthname(dbproc, language, monthnum, shortform) DBPROCESS *dbproc; char *language; int monthnum; DBBOOL shortform;
A pointer to the DBPROCESS structure that provides the connection for a particular front-end/server process. It contains all the information that DB-Library uses to manage communications and data between the front end and server.
The name of the desired language.
The number of the desired month. Month numbers range from 1 (January) to 12 (December).
A Boolean value indicating whether the long or short form of the month name is desired. If shortform is “true”, dbmonthname returns the short form of the month name; if shortform is “false”, dbmonthname returns the full month name. For example, if the month name desired is the U.S. English short form for January, “Jan” is returned.
Short forms of month names are defined in localization files on a per-localization-file basis.
The name of the specified month on success; a NULL pointer on error.
dbmonthname returns the name of the specified month in the specified language. If no language is specified (language is NULL), dbproc’s current language is used. If both language and dbproc are NULL, DB-Library’s default language (if any) is used.
The following code fragment illustrates the use of dbmonthname:
for (monthnum = 1; monthnum <= 12; monthnum++)
printf("Month %d: %s\n", monthnum,
dbmonthname((DBPROCESS *)NULL,
char *)NULL, monthnum, TRUE),
dbmonthname((DBPROCESS *)NULL, (char *)NULL, monthnum, FALSE));