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!

How do I save date with timestamp to the database?

smilingbanditMar 9 2010 — edited Mar 10 2010
Hi,

I am using Oracle Forms 6i. I have a form and a base table block which has an item of type 'Date'. My code puts in the current date by assigning 'sysdate' to the item. When the record is saved and I look at the value in the column on the table I find only the date with time as 12:00:00.

I tried changing the format mask of the item to HH12:MI:SS and that did not help. I also used the following

:block.item := TO_DATE(TO_CHAR(SYSDATE, 'DD-MON-YYYY HH24:MI:SS'),'DD-MON-YYYY HH24:MI:SS');

but that did not help either. The date in the table always appears with time stamp of 12:00:00. It is not that our database does not store dates with time stamps.

Am I missing something? Is there a way to save the sysdate with a timestamp to the database column using an item on a form?

Thanks for all your help in advance.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 7 2010
Added on Mar 9 2010
5 comments
3,655 views