**Source URL:** https://limited.veevavault.dev/regulatory/mdl/component-types/docfield

# Docfield

**Class:** `metadata`

Attribute of a document associated to one or more document types.

Learn about [Document Fields in Vault Help](https://platform.veevavault.help/en/lr/592).

| Attribute | Metadata | Description |
| --- | --- | --- |
| `secure_relationship` | Type: Boolean | Enables relationship security on a referenced object. |
| `shared` | Type: Boolean **Required** | Indicates whether the field is shared or local. |
| `multi_value` | Type: Boolean | Indicates whether the field accepts multiple values. |
| `display_section` | Type: String **Required** Max length: 1500 | Name of the display section. For example, `Docfieldlayout.general_properties__v` |
| `formula` | Type: Expression Max length: 4000 | An expression surrounded in `[ ]` character combination. |
| `blank_fields` | Type: String Max length: 1500 | options: zeros; blanks |
| `controlling_field` | Type: String Max length: 1500 | Controlling field name, if any. |
| `scale` | Type: Number | Applicable to fields of type number only. |
| `default_security` | Type: String Max length: 1500 | options: editable; readonly; hidden |
| `security_override_editable` | Type: String Max length: 1500 Multi-value | To specify users: `User.user@domain.com`. To specify groups: `Group.public_key__v`. |
| `security_override_readonly` | Type: String Max length: 1500 Multi-value | To specify users: `User.user@domain.com`. To specify groups: `Group.public_key__v`. |
| `security_override_hidden` | Type: String Max length: 1500 Multi-value | To specify users: `User.user@domain.com`. To specify groups: `Group.public_key__v`. |
| `set_on_create_only` | Type: Boolean | Can only set if the user has a proper MDL admin permission. |
| `editable` | Type: Boolean | Whether the field is editable by the user. The value here is specific to the user and depends on security\_overrides. |
| `hidden` | Type: Boolean | Indicates whether the field is hidden in the UI. The value here is specific to the user and depends on security\_overrides. |
| `defined_in` | Type: String Max length: 1500 | The Doc Type this field belongs to (local fields only). e.g. `Doctype.my_doc_type__c` |
| `used_in` | Type: String Max length: 1500 Multi-value | The Doc Type(s) this field is used in (shared fields only). e.g. `Doctype.my_doc_type__c` |
| `relationship_type` | Type: String Max length: 1500 | Can only return “reference” at this time. |
| `relationship_name` | Type: String Max length: 1500 | Auto-generated name based on the field name and the Vault object. |
| `lookupObjectFieldKey` | Type: String Max length: 1500 | Reference to Doc field component. Used for the Lookup field type. |
| `lookupObjectId` | Type: String Max length: 1500 | Reference to Object component. Used for the Lookup field type. |
| `lookupFieldId` | Type: String Max length: 1500 | Reference to Object field component. Used for the Lookup field type. |
| `relationship_criteria` | Type: String Max length: 1500 Multi-value | The VQL used to constrain records in the referenced `Object` |
| `no_copy` | Type: Boolean | When `true` a value will not be set in a copied document. Cannot be `true` when `required` is `true`. |
| `can_change_section` | Type: Boolean | For internal Veeva use only. |
| `can_change_required` | Type: Boolean | For internal Veeva use only. |
| `can_change_disabled` | Type: Boolean | For internal Veeva use only. |
| `can_change_multiple` | Type: Boolean | For internal Veeva use only. |
| `can_change_no_copy` | Type: Boolean | For internal Veeva use only. |
| `picklist` | Type: String Max length: 1500 | Reference to Picklist component. Used for the Picklist field type. |
| `help_content` | Type: String Max length: 500 | UI-friendly help string |
| `max_length` | Type: Number | Applicable to fields of type string only. |
| `active` | Type: Boolean **Required** | Indicates whether the field is active. |
| `required` | Type: Boolean **Required** | Indicates whether the field is required. |
| `type` | Type: String **Required** Max length: 1500 | options: String; Number; Boolean; Picklist; Date; URL; Formula; ObjectReference; Lookup |
| `default_value` | Type: String Max length: 1500 Multi-value | The default value used when the field is not set. |
| `object` | Type: String Max length: 1500 | Possible values supported are names of VOF objects, *User*, *Group*, and *Lifecycle*. |
| `queryable` | Type: Boolean | Indicates whether the field is queryable through VQL. This attribute is read-only. |
| `scope` | Type: String Max length: 1500 | options: Document; DocumentVersionRegular users can create Document scoped fields only. Creating DocumentVersion scoped fields requires special security permissions. |
| `min_value` | Type: Number | Applicable to fields of type number only. |
| `max_value` | Type: Number | For `Number` type fields, this is the maximum value allowed. For `ObjectReference` type fields where `multi-value` is set to `true`, this is the maximum number of records that can be selected in the field. If not specified, the default is 250 values. This attribute is not editable for `ObjectReference` type fields, but may have a specific value set for some system-managed fields. If the value is greater than 500, VQL queries return an unordered list. |
| `label` | Type: String **Required** Max length: 1500 | UI-friendly string in the Vault's base language. |

### Supported Operations

| Operation | Support |
| --- | --- |
| Create | Yes |
| Recreate | Yes |
| Alter | Yes\* |
| Drop | Yes |
| Rename | Yes |
| Describe | Yes |
| Generate Recreate | Yes |
| Queryable | No |

**Notes:**

*   **Alter:** MDL Operation may not be supported for some multi-value attributes.

---

**Previous:** [Docatomicsecurity](/regulatory/mdl/component-types/docatomicsecurity)  
**Next:** [Docfielddependency](/regulatory/mdl/component-types/docfielddependency)