Skip to Main Content

Database Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Strange Month Name With Mexican Spanish NLS_DATE_LANGUAGE

user2094682Nov 19 2009 — edited Nov 21 2009
I'm using oracle 10.2 and I have a little problem with date format.


First I'd like to know why I can't use the Mexican Spanish language in date convertion.

I mean the next queary fails..

select to_date('01-ENE-2009','DD-MON-YYYY','NLS_DATE_LANGUAGE=MEXICAN SPANISH') from dual

according to the documentation you can use any valid language but I've tried to do this whit others "compound" language such as CANADIAN FRENCH and it still doesn't work, any suggestion?

Second when SESSION - NLS_DATE_LANGUAGE is set to MEXICAN SAPANISH and I execute the next block

begin
for i in 1..12 loop
dbms_output.put_line(to_char(to_date(i,'MM'),'DD-MON-YYYY'));
end loop;
end;

The output is:

01-ENE-2009
01-FEB-2009
01-MAR-2009
...
...
01-NOV-2009
01-DEC-2009

All seems to be right but in spanish the 12th month is "DICIEMBRE" so the abbreviation should be "DIC". If I change the NLS_DATE_LANGUAGE to SPANISH it works correctly.

am I doing something wrong?

Regards
This post has been answered by Sergiusz Wolicki-Oracle on Nov 19 2009
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 19 2009
Added on Nov 19 2009
3 comments
3,666 views