I�ve configured an Adapter Notification to monitor inserts on two tables on a DB, using a join.
One of the tables is PurchaseOrder and the other is OrderLines, that is one PO can have one or more OrderLine.
The problem is that the document that the Adapter creates doesn�t allow more than one OrderLine.
How do I solve this??, do I have to use two adapters??
Yes, first there is a PurchaseOrder inserted on one table, then one (or many) OrderLines are associated with the PO on the other table, one by one.
Do you have some flag in the Purchase Order that says, entry for PurchaseOrder Lines is Completed?
No I don’t. The Adapter Notification is monitoring for an insert on both tables (using a join). When there is an insert that matches the join condition the document type is published by IS. The problem is the document type is automatically generated, and it doesn’t have a document list (the OrderLines).
The issue you are facing is, that notification fires for each row, so first record at OrderLine completes your Join. Rest of the notifications are ignored.
What you can do is… rather than using a join, use some flagging mechanism at PO Hearder, to say that lines are entered. On Trigger of the flag, capture Header and Lines.