Home » Developer & Programmer » Forms » master detail form
icon8.gif  master detail form [message #177102] Tue, 13 June 2006 01:35 Go to next message
rakas22
Messages: 29
Registered: May 2006
Junior Member
hi all,

In a master detail form, a detail block has ten records, among those ten, three records has the stock value as zero, so while committing the form, those three records should not save in to database, means out of 10, 7 records should save in database......

pls help me out

thank you all.
Re: master detail form [message #177106 is a reply to message #177102] Tue, 13 June 2006 01:56 Go to previous messageGo to next message
Maaher
Messages: 7065
Registered: December 2001
Senior Member
And why don't you make the 'stock value' column NOT NULL/required? If the information in the records is not stored it can never be retrieved again (the records are not in the database). I see absolutely no use of such a requirement.

MHE
Re: master detail form [message #177108 is a reply to message #177106] Tue, 13 June 2006 02:03 Go to previous messageGo to next message
rakas22
Messages: 29
Registered: May 2006
Junior Member
HI,

stock_value column is not null only. the value is zero. if the value is Zero then the paerticular record should not get stored in my database.
this is my requirement.

please help me out.
Re: master detail form [message #177111 is a reply to message #177108] Tue, 13 June 2006 02:13 Go to previous message
Maaher
Messages: 7065
Registered: December 2001
Senior Member
Sorry, my mistake. I misread your question. Iguess you *could* use coding to process the record when you commit, but it is my opinion that this is bad programming: records that are not inserted should not be entered in the first place.

You can solve it by not allowing the user to enter zero. You can enforce that by creating a WHEN-VALIDATE-ITEM trigger on the item notifying the user and failing the validation when the value is zero. Another option could be to set the 'minimum allowed value' property. But that will only work if your item should be a positive number only. In that case, no extra coding is needed: just a property.

MHE
Previous Topic: plsql table global access thru out the form
Next Topic: FRm-40509 oracle error : unable to update record
Goto Forum:
  


Current Time: Fri Sep 20 10:33:52 CDT 2024