SAP MDG · DATA MODEL UI

How do I set default values in SAP MDG Single Object Maintenance UIs?

In SAP MDG Single Object Maintenance, first identify whether the field is in the Change Request UIBB or the entity UIBB. For Change Request data, use enhancement, feeder inheritance plus Web Dynpro Customizing, or Web Dynpro Personalization; for entity data, use feeder-class code, Web Dynpro Personalization, or BAdI `USMD_RULE_SERVICE` with `DERIVE_ENTITY` for non-key fields.

In SAP MDG Single Object Maintenance, first identify whether the field is in the Change Request UIBB or the entity UIBB. For Change Request data, use enhancement, feeder inheritance plus Web Dynpro Customizing, or Web Dynpro Personalization; for entity data, use feeder-class code, Web Dynpro Personalization, or BAdI `USMD_RULE_SERVICE` with `DERIVE_ENTITY` for non-key fields.

In SAP MDG Single Object Maintenance, defaulting depends on whether the field belongs to the upper Change Request UIBB or the lower entity UIBB. The guide uses data model `SF` and entity `PFLI` as the example, and it shows three supported patterns for CR fields and three for entity fields, each with important limitations.

Process flow

  1. Identify whether the target field is in the Change Request UIBB or the entity UIBB.
  2. Choose the matching defaulting technique for that UIBB.
  3. For Change Request defaults, prefer enhancement in `CL_USMD_CR_GUIBB_GENERAL_DATA` or inheritance plus Web Dynpro Customizing.
  4. For entity defaults, prefer feeder-class code or inheritance from `CL_MDG_BS_GUIBB_FORM`.
  5. Use Web Dynpro Personalization only where user-specific defaults are acceptable.
  6. Use `USMD_RULE_SERVICE~DERIVE_ENTITY` only for non-key entity fields after key entry and roundtrip.
  7. Check the known limitations before implementation, especially personalization and dropdown behavior.
Web Dynpro Personalization

Open the UI, use the context menu of the supported field, and maintain the default value at user level

Set immediate, user-specific defaults for supported input fields and `DropDownByKey` controls

BAdI `USMD_RULE_SERVICE`

Implement method `DERIVE_ENTITY` for entity derivation logic

Derive default values for non-key entity fields after key entry

Referenced tables

ObjectPurpose
SAP MDG defaulting techniques by areaSummarizes which defaulting options are supported for Change Request data and entity data

The remaining configuration, implementation details, and testing guidance continue from this answer more…

Related questions and keywords

Alternative questions

  • How do I set default values in an MDG single-object UI?
  • How can fields be prepopulated in SAP MDG?
  • What options exist for default values in FPM BOL-based UIs?」「Can I default Change Request and entity fields?

Possible questions

  • Which data model is used in the guide?
  • Which entity demonstrates the default-value techniques?
  • What is the upper UIBB?
  • What is the lower UIBB?
  • Why are defaulting techniques different?
  • What are all ways to set defaults?
  • Which approaches work for CR data and entity data?
  • How do I default Change Request header data?

Keywords

SAP MDGdefault valuesSingle Object MaintenanceFPMBOLfeeder classChange RequestentityCL_USMD_CR_GUIBB_GENERAL_DATAIF_FPM_GUIBB_FORM~PROCESS_EVENTMO_ENTITYGET_PROPERTIESCL_MDG_BS_GUIBB_FORMUSMD_RULE_SERVICEDERIVE_ENTITYUSMD_UI_EVENT2USMD_ENTITY_VALUE2sap-config-mode=XSFPFLI