Is the relation you have created OK ? What are its properties ?
You can use also this - in a trigger when pressing "current record indicator" simply use:
Go_Block ('B');
execute_query;
and you will see records.
Main Topics
Browse All Topicshow to synchronize two block's data.
I have related two blocks. block B and block A are on the same canvas. One block A is based on view, and block B 's data is from block A's post-query trigger.
I want to see when I press each current record indicator for each record in block A, corresponding record in block B will be shown.
Now the problem is I cannot synchronize two block's data. For example, I input an ID in search block to bring up the block A, there are two records. There are also supposed two records in block B. But, in block B, there is only one record, always the last record from the post-query trigger.
Block A
ID DESC
123 ABC
246 HGJ
Block B
ID JOBS
123 ALEX (This line is missing)
246 BILL (only show this line)
I ever debug the post-query trigger and put the message statement to display the ID. The message can pop up both ID 123 and 246
Any ideas how to fix it?
I am using Oracle 8i database and application 11.0.3
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
I created the relation OK, but cannot pass the compiling. Error I mentioned above.
I tried your code. But, it doesn't work.
I use when-mouse-down trigger, i don't see the records changed when I go to first record. One thing is strange. In block B, always shown the last record when the form opened. When I use upper arrow or down arrow for the record, it only show the last record. But when I put a debug message to show record, I can see 2 records from the popped up message
I changed Number of Record property set to 2 or 3. It still only picks up one record also the last record. Block B doesn't have trigger at all. the Default Where property of block B is nothing there. Block A has Pre-Query trigger but it seems it doesn't say any data for Block B.
Any other suggestions to debug this problem?
I have read your first post:
"I have related two blocks. block B and block A are on the same canvas. One block A is based on view, and block B 's data is from block A's post-query trigger."
This is wrong - ... block B 's data is from block A's post-query trigger -> that is why there is only 1 last record. Post-Query trigger fires for each record so if there are 5 records in block A then in block B there will be record(s) for 5th record of block A.
You ought to set relation between block A and B and remove part corresponding part from Post-Query trigger of block A.
If there will be some compilation errors in ON-CHECK-DELETE-MASTER then you ougt to correct it (or post this trigger here and not only that there is an error).
I completely remove the post-query trigger in block A and copy everything from Block A's post-query trigger to Block B's post-query trigger. But, it seems nothing happened. Nothing displayed on the form for block B, block A's data is fine.
Even I put a debugging message on the top of the post-query trigger like below
message ('this is beginning');
declare
.......
the message is never shown up.
It seems that there is no relation between blocks A and B.
I don't understand the problem -> blocks A and B are based on table (view) -> block A has record(s) and in block B there must be corresponding record(s) => simply create relation between block A=master and B=child. I think that there is no need of post-Query trigger of block B because the relation will populate block B. Post-Query trigger of block B is needed only if there are some items not based on table columns you want to fill.
Now I understand. A Database Block Property of block B is set to NO.
In this case Post-Query trigger in block A is not a good option for populating block B. Also Post-Query trigger of block B will do nothing because this block is not a database block.
I would create a procedure for filling block B. This procedure can be called in a When-New-Record-Instance trigger of block A. In such scenario after going to another record in block A a corresponding records of block B will appear.
Business Accounts
Answer for Membership
by: wasabi3689Posted on 2009-10-11 at 12:47:35ID: 25547088
I ever tried to create a new relation between Block A and Block B by it common ID but, I got a compiler error
Compiling ON-CHECK-DELETE-MASTER trigger on XX_DOWNLOADS_V block...
Compilation error on ON-CHECK-DELETE-MASTER trigger on XX_DOWNLOADS_V block:
PL/SQL ERROR 103 at line 10, column 19
Encountered the symbol "(" when expecting one of the following:
a PL/SQL variable or double-quoted string
an expanded name
an expanded name link
a table reference expression
a key word
Resuming parse at line 12, column 52.