Re: Where best to validate multi-row block -- POST-FORMS-COMMIT

From: Mark C. Stock <mcstockX_at_Xenquery>
Date: Mon, 26 Jul 2004 10:40:23 -0400
Message-ID: <_OCdnV2RfaezhZjcRVn-rA_at_comcast.com>


"Mark C. Stock" <mcstockX_at_Xenquery .com> wrote in message news:DfmdneL266NPapncRVn-qw_at_comcast.com...
|
| "Roy Munson" <mtproc_at_yahoo.co.uk> wrote in message
| news:853055e7.0407260247.320beb34_at_posting.google.com...
| | Hi Guys....neither of these solutions works as the data has not been
| | posted to the database. So for example in the parent block i enter 10.
| | In the multi-row child i enter one row with the value 6 and a second
| | row with the value 5.
| |
| | In a pre-commit the data has not been posted to the database so the
| | validation of summing the child details will return zero each time.
| | Data then get committed and you have a summ of 11 stored where the top
| | block stated 10 to be the total value allowed.
| |
| | For when-validate-item....this is pretty much the same.
| |
| | The validation needs to be after data posted but before commit
| | transaction completed.
| |
| | Anybody got any clues...this must be a fairly regular scenario.
| |
| | TIA
| |
|
| presumably the assumption with the other suggestions is that you would
| validate the data in the blocks, not the data that has already been
written
| to the database -- so they do work with that proviso
|
| however, if you prefer to validate after rows have been written to the
| database, but before they are committed, you need to issue a forms POST
| command somewhere in your code prior to the validation -- as i recall,
POST
| will cause a message to be generated, so you also may need to set the
| MESSAGE_LEVEL setting, or use an ON-MESSAGE trigger (going by memory,
sorry
| if i didn't get the names quite right)
|
| however, you need to make sure what you are validating -- just the
| master/detail records that are being maintained via your form, or the
master
| record being maintained via your form and any and all detail records that
| exist in the database (whether or not they were maintained via your form)
|
| ++ mcs
|
|

clarification: i was thinking about what i had to do in older versions before the POST-FORMS-COMMIT trigger was implemented -- that is where you can issue SQL against that database just prior to the actual database commit, but after Forms issues all its insert, update, delete DML Received on Mon Jul 26 2004 - 16:40:23 CEST

Original text of this message