Re: Oracle Forms 4.5 and Date/Time fields

From: George Mari <marig_at_compuserve.com>
Date: 1996/07/05
Message-ID: <4rjuov$q6t_at_arl-news-svc-2.compuserve.com>#1/1


Yourname_at_somwhere.COM writes:
> ...
> I have a date field in which I have masked to show on hour and minutes
> (HH24":"MI). When an update is made and saved to this field, the
> database is updated with the correct time, but the date is changed to the
> first day of the current month. Example 6/17/96 07:30 would become
> 6/1/96 08:00 if the time was changed from 0730 to 0800.
>
> If the day and month a included within the mask or no mask is used, the
> problem goes away. Oracle support was of no help with this, they had
> never heard of this problem (BUG!).
> ...

This is not a bug. You cannot display and edit only the time portion of a date using just a format mask. You'll need a control item and some PL/SQL to attach the edited time back onto the date field. (Kludgey, but it works.)

Incidentally, the format mask you are using will cause problems with entries such as 1221 (translates to 12:01) or 1:2 (translates to 1:02). This again is not a bug. Oracle format masks 'zero fill' by default (See the online Forms help and search under 'Format Mask'). Zero fill is fine hours, but not minutes. Try HH24FX:MI instead.

George Mari
Oracle Specialist
Database Software Consulting, Inc.
73220.1277_at_compuserve.com Received on Fri Jul 05 1996 - 00:00:00 CEST

Original text of this message