X-Git-Url: http://xvm.mit.edu/gitweb/invirt/packages/invirt-database.git/blobdiff_plain/f76fb7d4c043b8e75ca0370ff1aeb082c53f12fc..23c43ee027ee2ae852c810139ae3ffc69f7cfe19:/python/database/models.py diff --git a/python/database/models.py b/python/database/models.py index 60cc025..77f4109 100644 --- a/python/database/models.py +++ b/python/database/models.py @@ -42,7 +42,7 @@ session = orm.scoped_session(orm.sessionmaker(transactional=False, autoflush=Fal machine_table = Table('machines', meta, Column('machine_id', Integer, primary_key=True, nullable=False), - Column('name', String, nullable=False), + Column('name', String, nullable=False, unique=True), Column('description', String, nullable=False), Column('memory', Integer, nullable=False), Column('owner', String, nullable=False),