misc/migration/3.10.7_Any.py
author Alexandre Fayolle <alexandre.fayolle@logilab.fr>
Mon, 17 Jan 2011 15:45:26 +0100
branchstable
changeset 6837 7562418985ef
parent 6815 a84190d4e78c
child 6852 970d1aab42a1
permissions -rw-r--r--
tutorial proof reading
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
6815
a84190d4e78c [schema] fix pb with ambiguous relation used within UniqueTogetherConstraint by having CWUniqueTogetherConstraint.relation targeting CWRType instead of CWAttribute/CWRelation. This fixes 3.10.7 migration.
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 6757
diff changeset
     1
add_relation_definition('CWUniqueTogetherConstraint', 'relations', 'CWRType')
a84190d4e78c [schema] fix pb with ambiguous relation used within UniqueTogetherConstraint by having CWUniqueTogetherConstraint.relation targeting CWRType instead of CWAttribute/CWRelation. This fixes 3.10.7 migration.
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 6757
diff changeset
     2
rql('SET C relations RT WHERE C relations RDEF, RDEF relation_type RT')
a84190d4e78c [schema] fix pb with ambiguous relation used within UniqueTogetherConstraint by having CWUniqueTogetherConstraint.relation targeting CWRType instead of CWAttribute/CWRelation. This fixes 3.10.7 migration.
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 6757
diff changeset
     3
commit()
a84190d4e78c [schema] fix pb with ambiguous relation used within UniqueTogetherConstraint by having CWUniqueTogetherConstraint.relation targeting CWRType instead of CWAttribute/CWRelation. This fixes 3.10.7 migration.
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 6757
diff changeset
     4
drop_relation_definition('CWUniqueTogetherConstraint', 'relations', 'CWAttribute')
a84190d4e78c [schema] fix pb with ambiguous relation used within UniqueTogetherConstraint by having CWUniqueTogetherConstraint.relation targeting CWRType instead of CWAttribute/CWRelation. This fixes 3.10.7 migration.
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 6757
diff changeset
     5
drop_relation_definition('CWUniqueTogetherConstraint', 'relations', 'CWRelation')
a84190d4e78c [schema] fix pb with ambiguous relation used within UniqueTogetherConstraint by having CWUniqueTogetherConstraint.relation targeting CWRType instead of CWAttribute/CWRelation. This fixes 3.10.7 migration.
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents: 6757
diff changeset
     6
6757
bc878ec35794 #1382705 forbid with sql level locking the simultaneous fireing of a transition on a given entity
Alexandre Fayolle <alexandre.fayolle@logilab.fr>
parents:
diff changeset
     7
add_attribute('TrInfo', 'tr_count')
bc878ec35794 #1382705 forbid with sql level locking the simultaneous fireing of a transition on a given entity
Alexandre Fayolle <alexandre.fayolle@logilab.fr>
parents:
diff changeset
     8
sync_schema_props_perms('TrInfo')