Added foreign key to wrreportcache.
authorphilipp <philipp@7aebc617-e5e2-0310-91dc-80fb5f6d2477>
Mon, 6 May 2013 20:27:54 +0000 (20:27 +0000)
committerphilipp <philipp@7aebc617-e5e2-0310-91dc-80fb5f6d2477>
Mon, 6 May 2013 20:27:54 +0000 (20:27 +0000)
git-svn-id: http://www.winterrodeln.org/svn/wrpylib/trunk@1421 7aebc617-e5e2-0310-91dc-80fb5f6d2477

wrpylib/wrmwdb.py

index 517567b078db024b4fb9467c52a12c092a44cc07..8efa7e38ed9cb380591397b5cffa767fba50d820 100644 (file)
@@ -124,7 +124,7 @@ def wrreportcache_table(metadata):
     return Table("wrreportcache", metadata,
     Column("page_id", types.Integer, primary_key=True),
     Column("page_title", types.Unicode(255), nullable=False),
-    Column("report_id", types.Integer),
+    Column("report_id", types.Integer, schema.ForeignKey('wrreport.id')),
     Column("date_report", types.Date),
     Column("condition", types.Integer),
     Column("description", types.Unicode),