diff --git a/InvenTree/company/migrations/0019_auto_20200413_0642.py b/InvenTree/company/migrations/0019_auto_20200413_0642.py index a27f56ce3a..509c45aaa2 100644 --- a/InvenTree/company/migrations/0019_auto_20200413_0642.py +++ b/InvenTree/company/migrations/0019_auto_20200413_0642.py @@ -22,7 +22,7 @@ def reverse_association(apps, schema_editor): cursor = connection.cursor() - response = cursor.execute("select id, MPN from part_supplierpart;") + response = cursor.execute('select id, "MPN" from part_supplierpart;') supplier_parts = cursor.fetchall() # Exit if there are no SupplierPart objects @@ -105,7 +105,7 @@ def associate_manufacturers(apps, schema_editor): cursor = connection.cursor() - response = cursor.execute("select id, MPN from part_supplierpart;") + response = cursor.execute(f'select id, "MPN" from part_supplierpart;') supplier_parts = cursor.fetchall() # Exit if there are no SupplierPart objects @@ -317,7 +317,7 @@ def associate_manufacturers(apps, schema_editor): # Extract all SupplierPart objects from the database cursor = connection.cursor() - response = cursor.execute("select id, MPN, SKU, manufacturer_id, manufacturer_name from part_supplierpart;") + response = cursor.execute('select id, "MPN", "SKU", manufacturer_id, manufacturer_name from part_supplierpart;') results = cursor.fetchall() part_count = len(results)