Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: year 2000 - Maybe a stupid question

Re: year 2000 - Maybe a stupid question

From: <suisum_at_freenet.edmonton.ab.ca>
Date: 23 Jul 1998 09:22:18 GMT
Message-ID: <6p6vca$kks$1@news.sas.ab.ca>


Hi:

The date format can be controlled in two levels:

  1. from database instance level. That is NLS_DATE_FORMAT = 'dd-MON-yyyy hh24:mi:ss'
  2. from session level. That is alter session set nls_date_format='dd-MON-yyyy hh24:mi:ss'

   You may use one of them.

Best regards,

Suresh Bhat (suresh.bhat_at_mitchell-energy.com) wrote:
: I apologize for my previous post.

: Sort on date type does work if nls_date_format is set to any valid date
: format other than the standard date format.

: I had some other problem when I used alter session set
: nls_date_format='dd-MON-yyyy hh24:mi:ss';
: I cannot recall or reproduce what it was but had to do something with sort
: and possibly using to_char, to_date.

: Sorry if I mislead anyone.

: Regards !!!

: suresh.bhat_at_mitchell-energy.com

: Rolf Hauck <Rolf.Hauck_at_datenrevision.de> wrote in article
: <35B578C0.75D3EF31_at_datenrevision.de>...
: > Hi,
: > the magic word you need is NLS_DATE_FORMAT. If you set this to the
: > format you prefer (try 'dd.mm.yyyy hh24:mi:ss'), you don't need those
: > ugly to_date/to_char functions.
: > You can set NLS_DATE_FORMAT in your Windows Registry for client access,
: > and even in your init.ora. For sqlplus on unix try creating a file
: > login.sql in your home-dir, containing "Alter Session set
: > NLS_DATE_FORMAT...".
Received on Thu Jul 23 1998 - 04:22:18 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US