Skip to content
+1-888-319-3663

COMMUNITY FORUM

Task execution

Brian asked 8 years ago
I have created a post document map success task to update the source record as integrated.  My problem is I'm not certain where to assign the record ID to a variable. What I am attempting to achieve is to assign the unique source recored ID to a variable then use the variable value in a SQL script after the document has been processed to update the integration status. 
Brian replied 8 years ago

I think I've figured out how to accomplish this however, now I have another issue. My map destination is to create GL journal entries. My key field is Batch since I want all source rows to be posted in a single batch. I notice that when the map executes it indicates that 1 record was processed. I assume that a record is the same as a document. If that is the case then the SQL command I have created to execute on each successful document is only being executed one time. Is it possible to setup the map so it will execute the task on each individual posting but still combine all postings into a single batch?

Answers
Best Answer
Chris answered 8 years ago
Brian,


You will want to add another key field or two so that the record count of the map matches how many gl transaction you actually have in the source. Normally you might use something like batchid, reference, and date or whatever unique combination of fields you have.

Then you want to group the create gl transaction node by those same fields. Everything will end up in the same batch as long as you have your batch field mapped to the batch parameter and it is the same throughout the source file. If the batch isn't there when hte map starts it will create it on the first document, and then just keep adding the other documents to it until the map is done or the batch id in your source changes.

H
Brian replied 8 years ago

I modifed my map to include the reference and date to the keys fields.  I am also grouping on the same fields, batch, reference, and date.  The value for the reference is the same for all records.  I am still only getting a single record being processed. 

Chris replied 8 years ago

If the map reports only one record as being processed then all the fields set as keys are the same for every record in the source file. The key fields set in a map determine how many records it is broken into when the map runs.

To get multiple records, fields need to be selected that form a unique key for each transaction in the source. The other condition that needs to be met is that any fields that are picked as key fields need to have values in them for each row of data.

H


If you would like to submit an answer or comment, please sign in to the eOne portal.