I have tried to update the fields using the following expression, however the data which got from interface is becoming null and record type is updating only with the expression values. Can any one pick it up and shoot it?
Discussion posts and replies are publicly visible
Is the data becoming null within the process model, or is it already null when received from the interface? We need more information about when exactly the data becomes null — is it after the update action or before?
It gets null after the update action in the script task.
please share the script task node's configuration (input and output)
Hi Shukur
Instead of a!update, create two custom outputs and save in respective fields. E.g. 1st output variable expression will be "RAJ12344" and saveinto will be your recordtype!recordname.fields.username. Similarly 2nd output variable will have true() in expression and save into isActive field of your record. This will leave all other fields of your record as it came from interface.
a!update() is making all other fields as null and doing operation on just the fields you mention in 'index'. So either do the above or mention all the fields in the index and corresponding values in 'value' of a!update.
a!update( pv!applicantInfo, {recordtype!record.userName, recordtype!record.isActive, recordtype!record.createdBy, recordtype!record.createdOn}, {"RAJ12344",true(),recordtype!record.createdBy, recordtype!record.createdOn})
Our best practice is to add a bunch of a!save(), one for each field, to the saveInto of the submit button to populate fields not entered by the user.
Hi Harsha,
Thank you so much for your reply. Yep I knew that however I was looking for a easy approach that should save in one go instead of creating multiple custom outputs for each field.
I tried to replicate your use case and was able to save the values in a record type variable. Make sure to save your process variable in the save into parameter of your "User Input Task" input.
Aww, thanks for your time dear. May I know what happend to other fields which are not updated in this update function? Does it become null?
When performing a test, the other fields of the variable do not become null.