**Source URL:** https://limited.veevavault.dev/medical/mdl/component-types/docfielddependency

# Docfielddependency

**Class:** `metadata`

Dependent fields allows you to configure a relationship between a controlling field and one or more controlled or dependent fields.

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

| Attribute | Metadata | Description |
| --- | --- | --- |
| `doctype` | Type: Component | The `Doctype` the field dependency applies to. |
| `docfield` | Type: Component | The `Docfield` the field dependency applies to. |
| `docfield_multi_value` | Type: String Max length: 2147483647 Multi-value | Specifies the field value or values that trigger the action. |
| `docfield_value` | Type: String Max length: 2147483647 | Specifies the field value that triggers the the action. This attribute cannot support individual values containing a comma, for example, “Tanzania, United Republic of”. This attribute is deprecated as of 19R2.3. |
| `deprule_docfield` | Type: Component **Required** | Specifies the `Docfield` the dependency rule applies to. |
| `deprule_docfield_action` | Type: Enum **Required** Allowed values: isHidden; isReadOnly; isVisible; isRequired; picklist | The action applied. Specifies the actions to take on the field values. |
| `deprule_docfield_multi_values` | Type: String Max length: 2147483647 Multi-value | The value(s) available when `deprule_docfield_action` is `picklist`. |
| `deprule_docfield_values` | Type: String Max length: 2147483647 | The value(s) available when `deprule_docfield_action` is `picklist`. This attribute cannot support individual values containing a comma, for example, “Tanzania, United Republic of”. This attribute is deprecated as of 19R2.3. |
| `lifecycle` | Type: String Max length: 2147483647 | The `Doclifecycle` the dependency rule applies to. |
| `state` | Type: String Max length: 2147483647 | The `Doclifecycle` state the dependency rule applies to. |
| `role` | Type: String Max length: 2147483647 | The `Doclifecycle` role the dependency rule applies to. |

### 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:** [Docfield](/medical/mdl/component-types/docfield)  
**Next:** [Docfieldlayout](/medical/mdl/component-types/docfieldlayout)