data not saved [message #467560] |
Mon, 26 July 2010 01:05 |
narang79
Messages: 137 Registered: June 2010
|
Senior Member |
|
|
sir i have a three blocks & three tables
1. master table composite primary key on(assm_no,assm_date)
2. a. input_detail table composite primary key on(assm_no,assm_date,input_item_code,process_code,fab_no)
b.input_detail table foreign key reference with master table
3. ouput detail table
foreign key references with master table
problem is
when form open master & input detail data auto coming
a., master table has one record.
b. input detail has two records.
c. output detail block data fetch according to input detail
means input detail has check box when we select one record & transfer record in output detail then data fetch in output detail block & saved
but if we select both records in input detail & trying to fetch in output detail then
data not saved in output block
first time data fetch in output detail but when cursor go back to input detail then output detail record also cleared
when i removed foreign key from output detail & then both records fetch in output block & saved
|
|
|
|
Re: data not saved [message #467572 is a reply to message #467565] |
Mon, 26 July 2010 02:00 |
narang79
Messages: 137 Registered: June 2010
|
Senior Member |
|
|
sir i have debug this form & i observe
when data fetch in output detail block then cursor & loop working
first time data fetch in output detail for first record
when cursor go back to input block then primary key triggers &
constranit fires & output detail block records clared
go_block ('output_detail');
last_record
data fetch;
go_block ('input_detail');
down;
exit when input_detail.item_code is null
when we write this wording data is not fetch in output detail block for single record or multiple recod in both cases
|
|
|
|
Re: data not saved [message #467579 is a reply to message #467560] |
Mon, 26 July 2010 02:23 |
narang79
Messages: 137 Registered: June 2010
|
Senior Member |
|
|
sir can u explain in detail
because i cant understand third block relation with master block then why third block cleared when cursor go back to second
block for next record
|
|
|
|
Re: data not saved [message #467594 is a reply to message #467582] |
Mon, 26 July 2010 03:12 |
narang79
Messages: 137 Registered: June 2010
|
Senior Member |
|
|
sir i m confused
actually i cant understand why this problem occured
i told in input detail block two records exists & both are checked
i have a push button when i press this button
loop & cusror working data fetch in output detail block for first record
but when cursor back to input detail block
output detail block records also cleared that will crate a problem for me
why is it link with master block because when i removed foreign key which is linked with master block then datasaved in output detail block
|
|
|
|
Re: data not saved [message #467612 is a reply to message #467599] |
Mon, 26 July 2010 04:22 |
narang79
Messages: 137 Registered: June 2010
|
Senior Member |
|
|
sir i think
when cursor go back to input detail block then on clear detail trigger fire & clear output detail block
so now i trying to solve it problem
|
|
|
|
Re: data not saved [message #467635 is a reply to message #467625] |
Mon, 26 July 2010 06:04 |
narang79
Messages: 137 Registered: June 2010
|
Senior Member |
|
|
sir third block is linked with first block (master block)
when cursor fetch data in third block after that back to second block then primary key on second block fire then on clear detail triger fire & clear third block records also which is linked with master block
but if i remove foreign key of third block then there is no problem in third block or otherwise
if i commented on clear block trigger then also no problem
|
|
|
Re: data not saved [message #467636 is a reply to message #467635] |
Mon, 26 July 2010 06:09 |
narang79
Messages: 137 Registered: June 2010
|
Senior Member |
|
|
actually primary key of second block creating problem
because forth block which is linked with second block is also cleraed when data fetch for multiple records
|
|
|
Re: data not saved [message #467641 is a reply to message #467636] |
Mon, 26 July 2010 06:28 |
narang79
Messages: 137 Registered: June 2010
|
Senior Member |
|
|
sir can u solve my query
when cursor is going on that block where primary key exists then what happened
actualy i think it will cleraed all records which is linked with it.
|
|
|