forked from 0x2620/pandora
fix index creation
This commit is contained in:
parent
e6aaf0aa6b
commit
2eafb9b3f8
2 changed files with 6 additions and 1 deletions
|
|
@ -3,7 +3,7 @@
|
|||
from optparse import make_option
|
||||
|
||||
from django.core.management.base import BaseCommand
|
||||
from django.db import connection
|
||||
from django.db import connection, transaction
|
||||
from django.conf import settings
|
||||
|
||||
import monkey_patch.models
|
||||
|
|
@ -42,3 +42,4 @@ class Command(BaseCommand):
|
|||
name = 'findvalue'
|
||||
if name not in indexes:
|
||||
create_table("%s_%s_idx"%(table_name, name), table_name, name)
|
||||
transaction.commit_unless_managed()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue