# -*- coding: utf-8 -*-
# Generated by Django 1.11.9 on 2018-02-07 07:49
"""
Migration adds unique indexes to materialized views so that they can be CONCURRENTLY updated
This should improve speed of execution and prevent deadlocks which are occasionally occuring
"""
from __future__ import unicode_literals

from django.db import migrations


class Migration(migrations.Migration):

    dependencies = [
        ('aims', '0052_add_commitment_vms'),
    ]

    operations = [
        # migrations.RunSQL('CREATE UNIQUE INDEX IF NOT EXISTS locationgeodata_concurrency ON aims_locationgeodata (location_id);'),
        # migrations.RunSQL('CREATE UNIQUE INDEX IF NOT EXISTS  transactionvalueusd_concurrency ON aims_transactionvalueusd (transaction_id);'),
        # migrations.RunSQL('CREATE UNIQUE INDEX IF NOT EXISTS  transactionvaluelocationview_concurrency ON aims_transactionvaluelocationview (location_id, transaction_id);'),
        # migrations.RunSQL('CREATE UNIQUE INDEX IF NOT EXISTS transactionvaluelocationsector_concurrency ON aims_transactionvaluelocationsector (transaction_id, location_id, sector_id);'),
    ]
