Home > Contents > Index >
DATEFORMAT.CREATE
Creates a date-format object, which is later used to convert between a date value and a displayable string.
Syntax
<DATEFORMAT.CREATE NAME="format object" [LOCALE="locale"] [DATESTYLE="style"] [TIMESTYLE="style"] [TIMEZONEID="zone"] />Parameters
NAME (required)
- Name of the date format object to create.
LOCALE (optional)
- Name of the locale object to use for this date-format object. If not specified, the default is the current Locale object.
DATESTYLE (optional)
- Style for date. Default is
MEDIUM
. The possible values are as follows:
SHORT
- Completely numeric, such as 12.13.52.MEDIUM
- Longer, such as Jan 12, 1952.LONG
- Longer, such as January 12, 1952.FULL
- Fully specified, such as Tuesday, April 12, 1952 AD.TIMESTYLE (optional)
- Style for time. Default is
MEDIUM
. The legal values are as follows:
medium
- (Default) Completely numeric, such as 3:30:42pm.full
- Fully specified, such as 3:30:42pm PST. The timezone will only be appended if it is specified by the timezoneid attribute.
TIMEZONEID (optional)
- Either an abbreviation such as "PST", a full name such as "America/Los_Angeles", or a custom ID such as "GMT-8:00". See TimeZoneID for a list of common TimeZone IDs.
Example
<SETVAR NAME="sourcedate" VALUE="CS.SQLDate"/>
Old Date: <CSVAR NAME="Variables.sourcedate"/><BR/><BR/>
Test For CST
<DATEFORMAT.CREATE NAME="DateObj" DATESTYLE="LONG" TIMESTYLE="MEDIUM" TIMEZONEID="CST"/>
<DATEFORMAT.GETDATETIME NAME="DateObj" VALUE="Variables.sourcedate" VALUETYPE="jdbcdate" VARNAME="hig_newdatetime"/>
New Date/Time: <STRING.STREAM VARIABLE="hig_newdatetime"/><BR/><BR/>
Test For IST
<DATEFORMAT.CREATE NAME="DateObj3" DATESTYLE="LONG" TIMESTYLE="MEDIUM" TIMEZONEID="IST"/>
<SETVAR NAME="sourcedate2" VALUE="CS.SQLDate"/>
<DATEFORMAT.GETDATETIME NAME="DateObj3" VALUE="Variables.sourcedate3" VALUETYPE="jdbcdate" VARNAME="hig_newdatetime3"/>
New Date/Time: <STRING.STREAM VARIABLE="hig_newdatetime3"/><BR/><BR/>Error Numbers
There are no possible
errno
for this tag.Release Introduced
This tag was introduced in CS release 5.0.
Home > Contents > Index > ![]()
Oracle XML Tag Reference
Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.