Skip to content

DBAzine.com

Sections
Personal tools
You are here: Home » Of Interest » Articles of Interest » Transition Constraints » Surprised about this article
Seeking new owner for this high-traffic DBAzine.com site.
Tap into the potential of this DBA community to expand your business! Interested? Contact us today.
Who Are You?
I am a:
Mainframe True Believer
Distributed Fast-tracker

[ Results | Polls ]
Votes : 3569
 

Comment

Above in this comment thread: Transition Constraints

Surprised about this article

Posted by abravo at 2006-01-28 09:07 AM
Hi Joe,
I don't agree with your proposal at all. Adding a column called previous_state to a table does not sound like a good design practice to me.

State transition in this case could be represented as a hierarchy and the checking of the constraint could be done against that hierarchy, of course in another table.

I would manage this situation as they do with data warehouses to maintain the history using slowly changing dimensions or treating the status changes as a fact.

Thanks

In defense of transition tables

Posted by jcelko at 2006-02-03 01:39 PM
The (current, prior) pairs are atomic data elements, just as (longitude, latitude) pairs are. They are the legal transitios modeled as the edges of a graph.

>> State transition in this case could be represented as a hierarchy and the checking of the constraint could be done against that hierarchy, of course in another table. <<

This is not a hierarchy! The diagram did not get printed with the article, but draw it by hand. The fact that transitions can have cycles means that they cannot be modeld as a hierarchy.

>> I would manage this situation as they do with data warehouses to maintain the history using slowly changing dimensions or treating the status changes as a fact. <<

A data warehouse stores **history**, I would model it with (start_time, end_time, status) triples and assume that the history is valid (i.e. grape juce did not turn into pudding or spoilage) because it came from OLTP databases with good transition constraints.

Transition constraints look at the presetn and the allowed future, the incompleted process of change, and steer it in the allowed directions.


 
Transaction Management
Reduce downtime and increase repeat sales by improving end-user experience.
Free White Paper
Database Recovery
Feeling the increased demands on data protection and storage requirements?
Download Free Report!
 
 

Powered by Plone