|
[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: Are people really using Identity constraints specified in
Hi Folks, Here are some thoughts: 1. Constraints on data are not equal to business rules. 2. Business rules change. Constraints on data do not. 3. Constraints on data should be specified in XML Schemas. Business rules should not. Business rules should be specified in higher level application code. Example: A company has employees. The current company policy on the minimum age requirement is 16. Should the company create an XML Schema that constrains <minimum-age> to 16? Or, should the company create an XML Schema that simply constrains <minimum-age> to an integer, and let applications higher up provide further constraints? Answers: - Mandating that the minimum age of an employee be 16 is a business rule. It is highly likely to change over time. - The value of the <minimum-age> must be an integer. This is a constraint on the data. It will not change over time. Therefore, an XML Schema should simply constrain <minimum-age> to be an integer. Higher level applications should implement the business rule that <minimum-age> be further constrained to 16. Comments? How would you characterize the distinction between "business rules" and "constraints on data"? /Roger
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|
|||||||||

Cart








