Skip to content
simone edited this page Jan 13, 2012 · 17 revisions

AIM

  • Use Django with embedded database that have composite multicolumn primary key and multiple foreignkeys
  • Low coupling with this specific API

API

from compositekey import db
class Blog(models.Model):
    id = db.MultiFieldPK("title", "author")
    title = models.CharField(max_length=100)
    author = models.CharField(max_length=100)

FEATURES

  • Django Query API (filters and exclude)
  • Standard ForeignKey API (OneToOne and ManyToMany)
  • Automatical Related Objects
  • Forms integration
  • Admin (no admin patch required)

REQUIREMENTS

  • Django 1.4-beta or Trunk

WORKING IN PROGRESS

  • django regression testing
  • new features tests

TESTING

  • SQLITE OK
  • ORACLE XE 11 90%
  • POSTGRES 9.1 50%
  • MYSQL 9.1 0%
  • DB2 40%

TODO

  • Generation of the schema -> low priority when you have an embedded database (Primary Key Constraints)
  • Command inspectdb

DECISION DESIGN NEEDED

  • Features of Generics Relations that are using joins between generic key and one non generic key
Clone this wiki locally