You have two Custom Data Types (CDT): ACME_invoice and ACME_invoiceItem that have a flat relationship.
The invoice item table has a field that is a foreign key to the invoice table. You are leveraging the database to automatically generate their primary keys.
How should you structure the process model to add a new invoice and the new invoice items to the system?
When dealing with related data types where one has a foreign key to another, you must first create the record in the primary table (ACME_invoice) and then use the generated primary key to create related records in the secondary table (ACME_invoiceItem). This is why you first write to the ACME_invoice table, then update the foreign keys in a Script Task, and finally write to the ACME_invoiceItem table.
Appian Documentation: Relational Databases
Catarina
3 months agoMagnolia
3 months agoDelmy
4 months agoSusana
4 months agoAlton
3 months agoLuann
3 months agoCecil
3 months agoJody
3 months agoSusana
3 months agoNgoc
4 months agoIra
4 months agoSamira
4 months agoChaya
4 months agoLynelle
2 months agoDominic
3 months agoNickolas
3 months agoVirgina
3 months agoMiles
3 months agoEve
4 months agoParis
4 months agoBrent
4 months ago