Skip to Main Content

Oracle Forms

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!

TO_DATE(TO_CHAR(sysdate, 'MM/DD/YYYY'), 'MM/DD/YYYY')

427608Nov 14 2005 — edited Nov 15 2005
Hi all,
I am working with a Oracle 9i R2 database

SQL>select TO_CHAR(sysdate, 'MM/DD/YYYY') CHRDATE from dual;

CHRDATE
----------
11/14/2005

SQL>select TO_DATE(TO_CHAR(sysdate, 'MM/DD/YYYY'), 'MM/DD/YYYY') mydate from dual;

MYDATE
---------
14-NOV-05

I want to retain the 4 digit year. Please suggest what I am doing incorrect.

Thanks

Comments

Martin-3221748

I have exactly the same issue with Oracle Instant Client 19.18 on Windows.

Visual Studio 2022 17.2.6

The same test program as listed above.

If compiled in debug mode, we hit:

Debug Assertion Failed!

Program: C:\Windows\SYSTEM32\MSVCP140D.dll
File: C:\PROGRA~2\MIB055~1\2017\PROFES~1\VC\Tools\MSVC\14.13.26128\include\xstring
Line: 3155

Expression: string subscript out of range

In Release Mode, the connect call goes through and in the dummy program it seems the connection is correctly established.

1 - 1
Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Dec 13 2005
Added on Nov 14 2005
2 comments
420,548 views