Legacy Knowledge Base
Published Jun. 30, 2025

Unable to adjust the Mandatory status of a field after publishing the Object Definition

Written By

Brian Suh

How To articles are not official guidelines or officially supporteddocumentation. They are community-contributed content and may not alwaysreflect the latest updates to Liferay DXP. We welcome your feedback toimprove How To articles!

While we make every effort to ensure this Knowledge Base is accurate,it may not always reflect the most recent updates or official guidelines.We appreciate your understanding and encourage you to reach out with any feedback or concerns.

Legacy Article

You are viewing an article from our legacy "FastTrack" publication program, made available for informational purposes. Articles in this program were published without a requirement for independent editing or verification and are provided"as is" without guarantee.

Before using any information from this article, independently verify its suitability for your situation and project.
Note: please note that Liferay has renamed its Liferay Experience Could offerings to Liferay SaaS (formerly LXC) and Liferay PaaS (formerly LXC-SM).

Issue

  • This article documents intended behavior where the Mandatory status of a field cannot be adjusted after publishing an Object Definition

Environment

  • Liferay DXP 7.4+
  • Liferay 2023.Q3+

Resolution

  • This is the intended behavior. After publishing the Object Definition, it is possible to save empty entries to a non-mandatory field. Therefore, we would have an inconsistent scenario if the field was made mandatory after empty entries have been saved.
  • On an Liferay SaaS environment, or if the Feature Flag for COMMERCE-8087 is enabled (i.e., configure portal-ext.properties to include feature.flag.COMMERCE-8087=true), we can workaround this behavior by exporting the Object entries, recreating the Object definition with the desired field changes, and reimporting it through Import/Export Center which is discussed in Batch Client Extensions article. Please note that as Feature Flags are experimental and/or beta functionality, they may be subject to change.

Additional Information

Did this article resolve your issue ?

Legacy Knowledge Base