Skip to content

Commit

Permalink
Merge pull request #11 from conwetlab/develop
Browse files Browse the repository at this point in the history
Fix #10: database initialization not working with CKAN 2.3 and postgresql 9.1.x
  • Loading branch information
aitormagan committed Jun 8, 2015
2 parents 40c6362 + 678c94a commit d273d21
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ckanext/datarequests/db.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ def get_ordered_by_date(cls, **kw):
datarequests_table = sa.Table('datarequests', model.meta.metadata,
sa.Column('user_id', sa.types.UnicodeText, primary_key=False, default=u''),
sa.Column('id', sa.types.UnicodeText, primary_key=True, default=uuid4),
sa.Column('title', sa.types.UnicodeText(constants.NAME_MAX_LENGTH), primary_key=True, default=u''),
sa.Column('description', sa.types.UnicodeText(constants.DESCRIPTION_MAX_LENGTH), primary_key=False, default=u''),
sa.Column('title', sa.types.Unicode(constants.NAME_MAX_LENGTH), primary_key=True, default=u''),
sa.Column('description', sa.types.Unicode(constants.DESCRIPTION_MAX_LENGTH), primary_key=False, default=u''),
sa.Column('organization_id', sa.types.UnicodeText, primary_key=False, default=None),
sa.Column('open_time', sa.types.DateTime, primary_key=False, default=None),
sa.Column('accepted_dataset_id', sa.types.UnicodeText, primary_key=False, default=None),
Expand Down Expand Up @@ -102,7 +102,7 @@ def get_ordered_by_date(cls, **kw):
sa.Column('user_id', sa.types.UnicodeText, primary_key=False, default=u''),
sa.Column('datarequest_id', sa.types.UnicodeText, primary_key=True, default=uuid4),
sa.Column('time', sa.types.DateTime, primary_key=True, default=u''),
sa.Column('comment', sa.types.UnicodeText(constants.COMMENT_MAX_LENGTH), primary_key=False, default=u'')
sa.Column('comment', sa.types.Unicode(constants.COMMENT_MAX_LENGTH), primary_key=False, default=u'')
)

# Create the table only if it does not exist
Expand Down

0 comments on commit d273d21

Please sign in to comment.