Stream: troubleshooting

Topic: compound metadata


view this post on Zulip Henning Timm (Jun 02 2023 at 09:58):

I am having some trouble with the visualization of (nested) compound metadata. Short version: I have a datasetField called "Parent" with type none and two related fields "Child A" and "Child B" that both allow multiple entries from controlled vocaularies and are nested under "Parent" (i.e. have "Parent" in the parent column).

view this post on Zulip Henning Timm (Jun 02 2023 at 09:59):

I can enter multiple values for the "Child A" and "Child B" fields but only the first entry is shown in the UI.

view this post on Zulip Henning Timm (Jun 02 2023 at 10:02):

E.g. if I enter "Child A": 1, 2, 3 , "Child B": 4, 5, 6 the metadata panel of the dataset will only show 1, 4.

view this post on Zulip Henning Timm (Jun 02 2023 at 10:05):

This is the problem discussed in https://github.com/IQSS/dataverse/issues/9200 right?

view this post on Zulip Henning Timm (Jun 02 2023 at 10:15):

Since there seems to be the possibility of SOLR not playing nicely with this pattern, is it advisable to use a flattened metadata schema instead?

view this post on Zulip Philip Durbin ๐Ÿš€ (Jun 02 2023 at 14:11):

@Henning Timm are you trying to do something like "Student's Program of Study" in this screenshot?

Screen-Shot-2023-06-02-at-10.10.30-AM.png

view this post on Zulip Philip Durbin ๐Ÿš€ (Jun 02 2023 at 14:12):

That block is here: https://github.com/IQSS/dataverse/blob/v5.13/scripts/api/data/metadatablocks/customGSD.tsv

view this post on Zulip Philip Durbin ๐Ÿš€ (Jun 02 2023 at 18:26):

Oh wait... you want a subfield. Hmm. :thinking:

view this post on Zulip Julian Gautier (Jun 04 2023 at 18:30):

I think I'm seeing the same thing. I adjusted one of the fields in the astronomy metadatablock so that it was a compound field with two subfields, where each subfield had a controlled vocabulary and allowed multiple values:

view this post on Zulip Julian Gautier (Jun 04 2023 at 18:30):

Screenshot-2023-06-04-at-7.28.08-PM.png

view this post on Zulip Julian Gautier (Jun 04 2023 at 18:31):

But Dataverse gives me error messages when saving the dataset with this metadata:
Screenshot-2023-06-04-at-7.28.28-PM.png

view this post on Zulip Julian Gautier (Jun 04 2023 at 18:32):

And when I view the metadata, only two of the controlled vocabulary terms are shown: the first term I chose from the first child field and the first term I chose from the second child field:
Screenshot-2023-06-04-at-7.28.36-PM.png

view this post on Zulip Julian Gautier (Jun 04 2023 at 18:36):

I don't think https://github.com/IQSS/dataverse/issues/9200 is related.

And I wonder if I would have this problem if I created a new metadatablock instead of editing the astronomy metadatablock that ships with Dataverse.

view this post on Zulip Henning Timm (Jun 05 2023 at 08:22):

Thanks for the fast replies!
Yes, my metadata block looks like what @Julian Gautier has reproduced. I did not get an error when saving, but my metadatablock was new, so that probably was the difference there.

view this post on Zulip Henning Timm (Jun 05 2023 at 08:23):

As a workaround, I decided to "flatten" the entry for now.

view this post on Zulip Julian Gautier (Jun 05 2023 at 13:49):

Thanks Henning. Channelling my inner-Phil here, would you like to open a GitHub issue to report this bug. Then I'm hoping folks can investigate the causes, such as if it's something to do with SOLR. Very recently I helped with a new metadatablock and we almost included fields like these, so we would have run into this bug, and others may run into the bug, too, where flattening wouldn't be a good workaround.

view this post on Zulip Henning Timm (Jun 06 2023 at 16:17):

Sure thing :) Thanks for the help.

view this post on Zulip Philip Durbin ๐Ÿš€ (Sep 07 2023 at 10:45):

@Henning Timm hi, did you ever create an issue for this?

view this post on Zulip Henning Timm (Sep 07 2023 at 11:04):

@Philip Durbin No, sorry, I did not get around to it. But my bad conscience is strong. I will try to get this done tomorrow.

view this post on Zulip Philip Durbin ๐Ÿš€ (Sep 07 2023 at 11:15):

Ha! Thanks! No rush! :big_smile:

view this post on Zulip Henning Timm (Sep 13 2023 at 22:18):

Finally :sweat_smile: https://github.com/IQSS/dataverse/issues/9911 Sorry for the delay.


Last updated: Oct 30 2025 at 06:21 UTC