Process Model Array of CDT save

So I have an interface that is saving two array of CDTs the idea I was having is that it would store each iteration of the array into its own respective row for the array example: {[uuid:1, fkuuid: ab32, date: today], [uuid:2, fkuuid: cd43, date: tomorrow]}. In the database there would be a row for UUID 1 and a row for UUID 2 but when I execute the write to data store entry I only get uuid 1. To push this even further I am doing this two times for separate tables and its only putting 1 entry into 1 table. 

If there is any more information that is needed let me know! 

Any Ideas on how to get it to save all the information in the array of cdt to each of its separate rows?

  Discussion posts and replies are publicly visible

Parents Reply Children
  • Okay! I will try this and report back my success rate! 

  • An error occurred while trying to write to the data store [TIMS]. No values have been written. Details: Batch update returned unexpected row count from update [0]; actual row count: 0; expected: 1 (APNX-1-4208-004)
    I got this Error and my Node looks like this:

  • 0
    Certified Lead Developer
    in reply to Kyle G

    Well, I would suggest you preform some debugging on your data that you are trying to store.

    It looks like  you don't have any data to store as the actual row count received by the smart service is 0 according to the error

    What are your process variables values of the process instance where this error occurred?


    Alternatively, you could also use 2 individual 'Write to Data Store Entity', one for Map_Producer and another for Map_Data_Producer 

  • My Process Variables are Arrays of CDTs:

    Map Producer:
    [uuid=, mapUuid=bd88c105-3b1f-42d8-a3f5-5230c4510ee9, producerUuid=28319bc1-d6c9-4113-92bc-ca0cd9c8d1f9, prime=True, createdDate=1/11/2022 12:00 AM, createdBy=admin.user, lastUpdatedDate=1/11/2022 12:00 AM, lastUpdatedBy=admin.user],

    [uuid=, mapUuid=bd88c105-3b1f-42d8-a3f5-5230c4510ee9, producerUuid=5ec6570b-ebf2-46c8-83ad-b9c182938264, prime=True, createdDate=1/11/2022 12:00 AM, createdBy=admin.user, lastUpdatedDate=1/11/2022 12:00 AM, lastUpdatedBy=admin.user],

    [uuid=, mapUuid=bd88c105-3b1f-42d8-a3f5-5230c4510ee9, producerUuid=28319bc1-d6c9-4113-92bc-ca0cd9c8d1f9, prime=True, createdDate=1/11/2022 12:00 AM, createdBy=admin.user, lastUpdatedDate=1/11/2022 12:00 AM, lastUpdatedBy=admin.user]

    ^ This is the array of CDTs I am talking about with the write to data store entity that I had in store before it only saved the first iteration of it which would be the one in bold.

    Map Data Producer:
    [uuid=, mapUuid=bd88c105-3b1f-42d8-a3f5-5230c4510ee9, producerUuid=5ec6570b-ebf2-46c8-83ad-b9c182938264, prime=True, createdDate=1/11/2022 12:00 AM, createdBy=admin.user, lastUpdatedDate=1/11/2022 12:00 AM, lastUpdatedBy=admin.user],

    [uuid=, mapUuid=bd88c105-3b1f-42d8-a3f5-5230c4510ee9, producerUuid=28319bc1-d6c9-4113-92bc-ca0cd9c8d1f9, prime=True, createdDate=1/11/2022 12:00 AM, createdBy=admin.user, lastUpdatedDate=1/11/2022 12:00 AM, lastUpdatedBy=admin.user],

    [uuid=, mapUuid=bd88c105-3b1f-42d8-a3f5-5230c4510ee9, producerUuid=5ec6570b-ebf2-46c8-83ad-b9c182938264, prime=True, createdDate=1/11/2022 12:00 AM, createdBy=admin.user, lastUpdatedDate=1/11/2022 12:00 AM, lastUpdatedBy=admin.user]

     

  • Thank you, Thank you, Thank you.  The solution you provided worked.

    Drive Mad