Re: POSTing in Oracle Form

From: Mark C. Stock <mcstockX_at_Xenquery>
Date: Mon, 15 Aug 2005 15:21:08 -0400
Message-ID: <P4SdneLUu7C1dp3eRVn-oQ_at_comcast.com>


"S.Chan" <someone_at_microsoft.com> wrote in message news:ddqdcr$2irr$1_at_news.hgc.com.hk...
>
> "Mark C. Stock" <mcstockX_at_Xenquery .com> wrote in message
> news:4MGdnT7Opp60LJ3eRVn-gQ_at_comcast.com...
>>
>> "S.Chan" <someone_at_microsoft.com> wrote in message
>> news:ddqcap$2i8v$1_at_news.hgc.com.hk...
>> > Hi All,
>> >
>> > I have some difficulities in using validating records via Oracle Forms.
>> > After I enter all the data in a record and before go to next record I
> need
>> > to validate it to make sure it's ok. THe rules needs to validate both
> the
>> > current record set (to be commited) and those in DB. What I could
>> > think to use is the POST statement.
>> >
>> > HOwever, in WHEN-VALIDATE-RECORD trigger I cannot use POST
>> > because POST is a restricted procedure! Nor I can use timer to trigger
>> > the posting.
>> >
>> > Are they any way to do this?
>> >
>> > Thanks for your suggestion. In response to my problem, please also
>> > copy to simonwychan_at_gmail.com. It's real urgent !!!
>> >
>> > Thanks again.
>> > Simon
>> >
>> >
>>
>> WHEN-NEW-ITEM-INSTANCE
>> WHEN-NEW-RECORD-INSTANCE
>>
>>
>
> Thanks for suggestions.
>
> But when-new-record-instnace fires only when i enter a new record.
> While i was in the new record, i cannot validate the previous one.
> can i?
>
>

you have to think through what forms is doing with internal navigation

if you navigate out of a record, it fires the when-validate-record trigger, which can reference the values in the record you are leaving

however, when you execute a POST built-in, Forms will issue the the INSERT (or UPDATE), then you can put code in your PRE-INSERT or PRE-UPDATE triggers.

or you can have your WHEN-VALIDATE-RECORD trigger save values into a package, and then call a validate routine from the WHEN-NEW-RECORD-INSTANCE trigger after it issues a POST

++ mcs Received on Mon Aug 15 2005 - 21:21:08 CEST

Original text of this message