Date and Time formatting

Gnumeric supports a wide variety of date and time formatting.

These formats can be used to convert an existing time serial number into a new more readable format, or dates can be entered in these formats and Gnumeric will automatically convert them to a serial number with the proper cell format. See the section called Dates and Numbers in Chapter 1 for more information.

In Example 3-3 'd' is a day, 'm' is a month, 'y' is a year, 'h' is an hour, and 's' is a second.

Example 3-3. Date and Time Formatting.

    Date
        Format                     Sample
   Serial number		36068.7	
   m/d/yyyy	        	10/1/1998	
   d-mmm-yy		        1-Oct-98	
   d-mmm-yyyy		        1-Oct-1998	
   d-mmm		        1-Oct	
   d-mm		                1-10	
   mmm/d		        Oct/1	
   mm/d		                10/1	
   mm/dd/yy		        10/01/98	
   mm/dd/yyyy		        10/01/1998	
   mmm/dd/yy		        Oct/01/98	
   mmm/dd/yyyy		        Oct/01/1998	
   mmm/ddd/yy		        Oct/Thu/98	
   mmm/ddd/yyyy		        10/01/1998	
   mm/ddd/yy		        10/Thu/98	
   mm/ddd/yyyy		        10/Thu/1998	
   mmm-yy		        Oct-98	
   mmm-yyyy		        Oct-1998	
   m/d/yy h:mm		        10/1/98 16:48	
   m/d/yyyy h:mm                10/1/1998 16:48	


Time

      Format                     Sample
  Serial number		       36068.7	
  h:mm:ss AM/PM		       4:51 PM	
  h:mm:ss AM/PM		       4:51:18 PM	
  h:mm		               16:51	
  h:mm:ss		       16:51:18	
  m/d/yy h:mm		       10/1/98 16:51	
  mm:ss		               10:18	
  mm:ss.0		       10:1836068.7	
  [h]:mm:ss		       :10:18