By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,007 Members | 1,248 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,007 IT Pros & Developers. It's quick & easy.

Date format db2 udb

P: n/a
SQL ref Vol. 1, page 102 gives 4 (or 5) different formats with their
names and abbreviations. Unfortunately, I see no mention of where to
specify the name or abbreviation to get the one I want. This must be
terribly obvious to those of you who have done, but I'm at a loss.
Nov 12 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
"Bob Stearns" <rs**********@charter.net> wrote in message
news:Tv************@fe04.lga...
SQL ref Vol. 1, page 102 gives 4 (or 5) different formats with their names
and abbreviations. Unfortunately, I see no mention of where to specify the
name or abbreviation to get the one I want. This must be terribly obvious
to those of you who have done, but I'm at a loss.


If it is not listed, then it is not available. However, you may be able to
write your own user-exit or just create a UDF to reformat it for you.
Nov 12 '05 #2

P: n/a
Mark A wrote:
"Bob Stearns" <rs**********@charter.net> wrote in message
news:Tv************@fe04.lga...
SQL ref Vol. 1, page 102 gives 4 (or 5) different formats with their names
and abbreviations. Unfortunately, I see no mention of where to specify the
name or abbreviation to get the one I want. This must be terribly obvious
to those of you who have done, but I'm at a loss.

If it is not listed, then it is not available. However, you may be able to
write your own user-exit or just create a UDF to reformat it for you.

You missed the thrust of my question ( almost expected it, there was a
great SF short story about this titled something like "I forget" ). I
don't want to define another format, I want to know where to specify one
of these formats: ddl, dml, some esoteric CLI, startup parameters of
DB2, some place that hasn't even occurred to me?
Nov 12 '05 #3

P: n/a
"Bob Stearns" <rs**********@charter.net> wrote in message
news:xG*************@fe04.lga...
You missed the thrust of my question ( almost expected it, there was a
great SF short story about this titled something like "I forget" ). I
don't want to define another format, I want to know where to specify one
of these formats: ddl, dml, some esoteric CLI, startup parameters of DB2,
some place that hasn't even occurred to me?


The default external data format (DB2 always stores dates internally the
exact same way regardless of how it is displayed) is automatically defined
by the country code of the database installation. I believe it can also be
defined by a client installation parms.

To retrieve the date format in a specified format for an individual SQL
statement (regardless of the above) you can use the CHAR SQL function:

SELECT CHAR(HIREDATE, ISO) FROM EMPLOYEE;
Nov 12 '05 #4

P: n/a
Mark A wrote:
"Bob Stearns" <rs**********@charter.net> wrote in message
news:xG*************@fe04.lga...
You missed the thrust of my question ( almost expected it, there was a
great SF short story about this titled something like "I forget" ). I
don't want to define another format, I want to know where to specify one
of these formats: ddl, dml, some esoteric CLI, startup parameters of DB2,
some place that hasn't even occurred to me?

The default external data format (DB2 always stores dates internally the
exact same way regardless of how it is displayed) is automatically defined
by the country code of the database installation. I believe it can also be
defined by a client installation parms.

To retrieve the date format in a specified format for an individual SQL
statement (regardless of the above) you can use the CHAR SQL function:

SELECT CHAR(HIREDATE, ISO) FROM EMPLOYEE;

Thank you, that was the answer I was looking for.
Nov 12 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.