Sun Java System Calendar Server 6 2005Q4 Administration Guide

Date Sub-Formatting

Date-time values can be formatted in many different ways. Using a sub-format, you can provide additional information to describe how a date-time value should be formatted. If a sub-format is not specified, the server uses a default format to output the date. Using a sub-format field allows you to specify the exact format to be used.

For example, %B specifies that the output string includes the event's begin time. This default format prints out the date, time, the time zone, and everything possible about the date. The sub-format string for date values is a strftime format string (see Special Character Sequences for Dates). If you were only interested in the month and year of the start time, instead of %B, you would use: %(%m %Y)B.

Example

The following example:


The event begins: %B%N
 The event ends: %(%b %d, %Y %I:%M %p)E%N

produces output that resembles the following notification:


The event begins Feb 02, 1999 23:30:00 GMT Standard Time
 The event ends Feb 03, 1999 02:30 AM