Last active
April 7, 2017 04:40
-
-
Save tgroshon/b40eaf01dbec78e132d594c63516a75d to your computer and use it in GitHub Desktop.
Why does this lock my table for reading? How do I make it NOT lock the table?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
# Generated by Django 1.10.5 on 2017-03-29 16:51 | |
from __future__ import unicode_literals | |
from django.db import migrations, models | |
class Migration(migrations.Migration): | |
dependencies = [ | |
] | |
operations = [ | |
migrations.AddField( | |
model_name='mymodel', | |
name='newfield', | |
field=models.TextField(blank=True, null=True), | |
), | |
] | |
# -- Translates into this SQL -- | |
# BEGIN; | |
# ALTER TABLE "app.mymodel" ADD COLUMN "newfield" text NULL; | |
# ALTER TABLE "app.mymodel" ALTER COLUMN "newfield" DROP DEFAULT; | |
# COMMIT; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment