This is an automated email from the ASF dual-hosted git repository.
beto pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-superset.git
The following commit(s) were added to refs/heads/master by this push:
new e2b9625 Increase size of column `name` in table `ab_view_meu` (#6532)
e2b9625 is described below
commit e2b9625d84490e7d7bc82be74a84766be66498bd
Author: Beto Dealmeida <[email protected]>
AuthorDate: Tue Dec 18 10:57:45 2018 -0800
Increase size of column `name` in table `ab_view_meu` (#6532)
* Create migration script
* Use batch operation for ALTER COLUMN
---
...d38_increase_size_of_name_column_in_ab_view_.py | 34 ++++++++++++++++++++++
1 file changed, 34 insertions(+)
diff --git
a/superset/migrations/versions/cefabc8f7d38_increase_size_of_name_column_in_ab_view_.py
b/superset/migrations/versions/cefabc8f7d38_increase_size_of_name_column_in_ab_view_.py
new file mode 100644
index 0000000..f808ca2
--- /dev/null
+++
b/superset/migrations/versions/cefabc8f7d38_increase_size_of_name_column_in_ab_view_.py
@@ -0,0 +1,34 @@
+"""Increase size of name column in ab_view_menu
+
+Revision ID: cefabc8f7d38
+Revises: 6c7537a6004a
+Create Date: 2018-12-13 15:38:36.772750
+
+"""
+
+# revision identifiers, used by Alembic.
+revision = 'cefabc8f7d38'
+down_revision = '6c7537a6004a'
+
+from alembic import op
+import sqlalchemy as sa
+
+
+def upgrade():
+ with op.batch_alter_table('ab_view_menu') as batch_op:
+ batch_op.alter_column(
+ 'name',
+ existing_type=sa.String(length=100),
+ existing_nullable=False,
+ type_=sa.String(length=255),
+ nullable=False)
+
+
+def downgrade():
+ with op.batch_alter_table('ab_view_menu') as batch_op:
+ batch_op.alter_column(
+ 'name',
+ existing_type=sa.String(length=255),
+ existing_nullable=False,
+ type_=sa.String(length=100),
+ nullable=False)