You are viewing limited content. For full access, please sign in.

Question

Question

Setting Multivalue date fields

SDK
asked on October 16, 2020

So, I have a template that contains police case records and a multivalue group of name fields associated with that case. One of the name fields is the person's Date of Birth. When adding the multivalue fields all of the name fields are grouped correctly, unless one of the names is missing the DOB. If, the first name is missing the DOB, the first DOB that is not null gets assigned to that first person. If any other DOB fields are missing they all get shifted up in the hierarchy. For example...

FieldName FieldValue
Case Id 12345
First Name John
Last Name Smith
DOB
First Name Mary
Last Name Doe
DOB 1/1/1980
First Name Jane
Last Name Doe
DOB
First Name Ralph
Last Name Smith
DOB 2/2/1970

When the template is populated, the information gets populated like this...
FieldName FieldValue
Case Id 12345
First Name John
Last Name Smith
DOB 1/1/1980
First Name Mary
Last Name Doe
DOB 2/2/1970
First Name Jane
Last Name Doe
DOB
First Name Ralph
Last Name Smith
DOB

Notice if the DOB is null for the first person, the first non-null date gets populated until there are no more dates. Then the remaining "groups" have null values for the DOB. Every other field stays with it's appropriate "group", except the dates. How do I pass an empty date value to a multi-value date field so that they are all with the appropriate "group"?

Has anyone else experienced this? I've found a work-around by sorting the names based on a DESC DOB before adding them to my FieldValueCollection, but that seems a bit unnecessary. Every other field works like it should. The Date field is the only one giving me problems. It's as if, the SDK doesn't know how to handle NULL or Empty values for Dates.

0 0

Replies

replied on April 10, 2023

Hello Keith Hay,

Have you found any solution for blank or null value fetching from laserfiche sdk for multi-value ?

https://answers.laserfiche.com/questions/207855/LF-SDK-problem-with-getting-group-stage-with-multivalue-fields--if-multivalue-field-is-blank

I have similar problem and searching solution.

Thanks,

pratik 

 

0 0
replied on April 10, 2023

No...I had to sort the names by the Date of Birth field before adding them to my field collection. That way, all rows that had Birthdate's were populated first, and then those that didn't were populated last with empty birthdate fields.

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.