[Pycon2005-attendees] The Database Divide

Patrick K. O'Brien pobrien at orbtech.com
Fri Mar 25 16:44:16 CET 2005

Andy Dustman wrote:
> The biggest mismatch is still that your Python objects may point to
> instance of arbitrary classes. In a relational database, this is like
> having a column with a foreign key reference, except that it might
> refer to a key in an arbitrary table for each row, which you just
> can't do.

Unless you are using Schevo, which allows you to set constraints on
references that limit them to instances of one particular class[1],
rather than any arbitrary class.

[1] Actually, Schevo lets you constrain to one class, or a list of
classes, which is a unique advantage that it has over relational foreign
keys.  (And, yes, those can still be exported to SQL by creating one SQL
field for each class in the list.  So if your reference field in Schevo
allowed a reference to an instance from one of three different Entity
classes, the exported SQL table would contain 3 foreign key fields
instead of one.)

Patrick K. O'Brien
Orbtech    http://www.orbtech.com
Schevo     http://www.schevo.org
Pypersyst  http://www.pypersyst.org

More information about the Pycon2005-attendees mailing list