mirror of
https://github.com/asterisk/asterisk.git
synced 2025-10-06 05:02:29 +00:00
alembic: Add support for MS-SQL
MS-SQL has no native Enum-type support and therefore needs to work with constraints. Since these constraints need unique names the suggested approach referenced in the following alembic documentation has been applied: http://bit.ly/2x9r8pb ASTERISK-27255 #close Change-Id: I4a399ba3eed41a33ce8cb294968ad340221580ee
This commit is contained in:
committed by
Kevin Harwell
parent
9a366d2424
commit
ad606844be
@@ -45,4 +45,6 @@ def upgrade():
|
||||
op.add_column('ps_endpoints', sa.Column('rpid_immediate', yesno_values))
|
||||
|
||||
def downgrade():
|
||||
if op.get_context().bind.dialect.name == 'mssql':
|
||||
op.drop_constraint('ck_ps_endpoints_rpid_immediate_yesno_values','ps_endpoints')
|
||||
op.drop_column('ps_endpoints', 'rpid_immediate')
|
||||
|
Reference in New Issue
Block a user