How can I set a default value for a text field when doing Metadata Customization?
I am assuming you are creating a new metadata block?
After the metadata block is set up, you can set up a Dataset template and add a "default value" in the metadata template.
https://guides.dataverse.org/en/latest/user/dataverse-management.html#dataset-templates
Sherry Lake said:
I am assuming you are creating a new metadata block?
After the metadata block is set up, you can set up a Dataset template and add a "default value" in the metadata template.
https://guides.dataverse.org/en/latest/user/dataverse-management.html#dataset-templates
I mean when creating a tsv file.
You can add a watermark. Does that help? "A string to initially display in a field as a prompt for what the user should enter." -- https://guides.dataverse.org/en/6.1/admin/metadatacustomization.html#datasetfield-field-properties
But I want to have it as a real default value and not just watermark
I see. Similar to how the author is pre-populated by the person who is logged in?
Yes, for instance.
I don't think anyone has asked for this, or at least I can't find a GitHub issue for it. Please feel free to create one.
Most people use dataset templates for this, as Sherry mentioned. That won't work for you?
You know, I am generating the metadata on the fly and importing to the dataverse using its API; so having the capability to define a default value when generating TSV file is important for me.
Ah, and dataset templates are (currently) a GUI-only feature. Makes sense. Are you interested in creating an issue?
Not sure yet. I should discuss with our team lead to see what to do.
Mohsen Jafari has marked this topic as resolved.
@Mohsen Jafari I see new issue at #10387 that sounds very similar. Was is created by someone on your team?
Yes, that's my colleague.
Ah, perfect, that's what I figured. Thanks!
Last updated: Oct 30 2025 at 06:21 UTC