-- YugabyteDb supports `IF NOT EXISTS` syntax when creating indexes.
-- If an index already exists with the same name, it will not be duplicated.
-- However, you should still review your pre-existing indexes in advance
-- to make sure you do not already have one or more of the same indexes
-- defined under a different name. If so, you should omit them
-- from what you apply to your YugabyteDb database.

CREATE INDEX IF NOT EXISTS idxg4n7i9f9yxxyvq622pvp4qlhd ON blc_advanced_tag(context_id);
CREATE INDEX IF NOT EXISTS idxjfyxn5ui218erach3syrpsnr0 ON blc_advanced_tag(name);
CREATE INDEX IF NOT EXISTS idx2pkufefbdya9qir844u836cgy ON blc_advanced_tag(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idxph15yv6c3kdiyaow1dysipor ON blc_advanced_tag(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idxqg9idxag2t5enkm305bvxu71d ON blc_advanced_tag(trk_application_context_id);
CREATE INDEX IF NOT EXISTS idxosj785tkew6sxuw6sd26k70qk ON blc_application_catalog(context_id);
CREATE INDEX IF NOT EXISTS idxlj2n3wdt6u930s8c5g28hh0yr ON blc_application_catalog(application_id);
CREATE INDEX IF NOT EXISTS idxo9ysroyx17nrb02mef9qf3qjl ON blc_catalog(vendor_ref);
CREATE INDEX IF NOT EXISTS idx1swm3w6cwnt8gvt8mad3ctbqn ON blc_catalog(owning_application);
CREATE INDEX IF NOT EXISTS idxdhgo9plctwffx0gqa4ujgbsn0 ON blc_category(context_id);
CREATE INDEX IF NOT EXISTS idxq8oqcsl13aa27hddrq9cma3qd ON blc_category(name);
CREATE INDEX IF NOT EXISTS idxoiq5mjh7u2hq5wtnw3rgxcwr3 ON blc_category(parent_category_context_id);
CREATE INDEX IF NOT EXISTS idxj0pbgv599cu89vn0fe1d8qvsc ON blc_category(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idxavi05t1bt8x0c0q73nuy0n2kb ON blc_category(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idxnxoyn02t8nxc557830b7p3koa ON blc_category(trk_catalog_context_id);
CREATE INDEX IF NOT EXISTS idxobr2b4dyjpily81pg3kpof1ge ON blc_category(trk_parent_cat_context_id);
CREATE INDEX IF NOT EXISTS idxq2cj94jj781xynf78muuobwra ON blc_category_asset(context_id);
CREATE INDEX IF NOT EXISTS idxar0db0v8m5fhnaea0f3vt5les ON blc_category_asset(category_context_id);
CREATE INDEX IF NOT EXISTS idx4aiqdvn7dabexbtmjsjcx20y8 ON blc_category_asset(sorting);
CREATE INDEX IF NOT EXISTS idx5hcnx2j0xho7e7iuo5whi4ksm ON blc_category_asset(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idxdniv8sxf4tgx3fno0sj24o52 ON blc_category_asset(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idx81lmlgc0ggbmqwb6yxjo4oxdh ON blc_category_asset(trk_catalog_context_id);
CREATE INDEX IF NOT EXISTS idx5uo0ll5l49sdffhh97ivbyb5 ON blc_category_asset(trk_parent_cat_context_id);
CREATE INDEX IF NOT EXISTS idxbvjasoq7dhnx7h23i311somp ON blc_category_product(context_id);
CREATE INDEX IF NOT EXISTS idxr1jhge7lx96ri5x7kttgeilnk ON blc_category_product(product_context_id);
CREATE INDEX IF NOT EXISTS idxkwa1n5dehtb4ex2rnau8pegnb ON blc_category_product(category_context_id);
CREATE INDEX IF NOT EXISTS idx3l9fd887ikiwldflfhb63atf6 ON blc_category_product(sorting);
CREATE INDEX IF NOT EXISTS idx6cgxjkj4s4pyrgu1kkvp6ompf ON blc_category_product(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idx8vq9oo9kojgb25qdi5gy309bd ON blc_category_product(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idxa4c3td9wgrgennqu9q0q7f1o6 ON blc_category_product(trk_catalog_context_id);
CREATE INDEX IF NOT EXISTS idxqmrhwjxc8xhdh38r2yjsikdd3 ON blc_category_product(trk_parent_cat_context_id);
CREATE INDEX IF NOT EXISTS idxa33lm6c46b115to65kxyfs0i ON blc_data_driven_enum(context_id);
CREATE INDEX IF NOT EXISTS idxq9nyewpapix4afhpbaeqs8ids ON blc_data_driven_enum(type);
CREATE INDEX IF NOT EXISTS idxc34nwhaaaq5t9pa4qadv08h59 ON blc_data_driven_enum(value);
CREATE INDEX IF NOT EXISTS idx7g3lnnhp189ps2pmb0g7f3lqn ON blc_data_driven_enum(trk_application_context_id);
CREATE INDEX IF NOT EXISTS idxatxfxgsbdu0t44r3rmwl2pabw ON blc_data_driven_enum(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idxi6mrq2se3m675y3f2sfjud9mc ON blc_data_driven_enum(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idxnpaip70ba44d2at7ewbhxsvd8 ON blc_mpl_appl_cat(catalog_id);
CREATE INDEX IF NOT EXISTS idxjgrwuebh95ixqw5r975ymmy9f ON blc_mpl_appl_cat(application_id);
CREATE INDEX IF NOT EXISTS idx7i0i5vcl1dkkwuq5dyc88wem5 ON blc_notification_state(acked);
CREATE INDEX IF NOT EXISTS idxgfaqe3xmq5q4yh78mix1g04fy ON blc_notification_state(container);
CREATE INDEX IF NOT EXISTS idx6i5kjfaeoppavs2th5dmktbcr ON blc_option_template(context_id);
CREATE INDEX IF NOT EXISTS idx9oask9e8jbwacgys7w15bv7o ON blc_option_template(name);
CREATE INDEX IF NOT EXISTS idx92pp0v5812dpdr4gj7gmladpf ON blc_option_template(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idxco88tby1ds7x8g4ihil4wjqnf ON blc_option_template(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idxdidymx7cwl346d6p3m0wgikr ON blc_option_template(trk_catalog_context_id);
CREATE INDEX IF NOT EXISTS idx8y0sffa9t7p4e99cwvv2o3ge1 ON blc_option_template(trk_parent_cat_context_id);
CREATE INDEX IF NOT EXISTS idx2are2fjnqgpf2g6rgggrlmi9j ON blc_option_template_group(context_id);
CREATE INDEX IF NOT EXISTS idx9sff79mk3l57b1rvn0ki4chiy ON blc_option_template_group(name);
CREATE INDEX IF NOT EXISTS idxk9ryac4flg363wyuhkc5flwop ON blc_option_template_group(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idx9x77lt8tdk429my3d05h339rh ON blc_option_template_group(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idxn3d0yowqeiel0lygs86n71okv ON blc_option_template_group(trk_catalog_context_id);
CREATE INDEX IF NOT EXISTS idxdh92fe7ctsy5xrkjmmyw2lsaj ON blc_option_template_group(trk_parent_cat_context_id);
CREATE INDEX IF NOT EXISTS idxsjbj4rdo82qd2ojjx70tcmr5p ON blc_product(context_id);
CREATE INDEX IF NOT EXISTS idxa9p74kgrri0pekbwuuh069m0m ON blc_product(name);
CREATE INDEX IF NOT EXISTS idx5igej4hbx1lpw2hg94f7ilol ON blc_product(sku);
CREATE INDEX IF NOT EXISTS idxl4fkqkahuyc7hf5usrxs9opgy ON blc_product(upc);
CREATE INDEX IF NOT EXISTS idxrm4mwbjjkgq0ws6miglleh4gr ON blc_product(external_id);
CREATE INDEX IF NOT EXISTS idx1te66j6q8qiumivwnrv2nkjmk ON blc_product(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idx4al4pkcxobty6ttdi257u7tnv ON blc_product(uri);
CREATE INDEX IF NOT EXISTS idx7kpbp96xjcyy32ytwcdthxbrb ON blc_product(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idx9xwgoac2pxyl6paimm2cdky6y ON blc_product(trk_catalog_context_id);
CREATE INDEX IF NOT EXISTS idxsv9p8jkqu6k8m4pnk36yhqqfr ON blc_product(trk_parent_cat_context_id);
CREATE INDEX IF NOT EXISTS idxqb5crjlkxfwgklpiyvg3cfkvm ON blc_product(tags);
CREATE INDEX IF NOT EXISTS idxs8u21jqqyhlj1xfb1lj9a0xyo ON blc_product_asset(context_id);
CREATE INDEX IF NOT EXISTS idx28jtvt8i3nt4jjm6soax4efbt ON blc_product_asset(product_context_id);
CREATE INDEX IF NOT EXISTS idxsjyj32aa946un7wa3yuc5k8v0 ON blc_product_asset(sorting);
CREATE INDEX IF NOT EXISTS idxjjl772wo6ydeahke0o7kdfqc0 ON blc_product_asset(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idxjbbwp9if64pcwsv2w4vnh813g ON blc_product_asset(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idxrpf2bkipe3qxw8r481mavs1os ON blc_product_asset(trk_catalog_context_id);
CREATE INDEX IF NOT EXISTS idx9d5apxhyoajtx60nd6w3mwsc ON blc_product_asset(trk_parent_cat_context_id);
CREATE INDEX IF NOT EXISTS idx6qvnm0evps91hif4g87yy6nhk ON blc_product_tag(context_id);
CREATE INDEX IF NOT EXISTS idxo7sc6fb924o3ayfug0m3i09sl ON blc_product_tag(product_context_id);
CREATE INDEX IF NOT EXISTS idxab7fyskapknfm18s4ddck9wb ON blc_product_tag(tag_context_id);
CREATE INDEX IF NOT EXISTS idxlyvh1xrjwm2l5qg6n0w028b7u ON blc_product_tag(sorting);
CREATE INDEX IF NOT EXISTS idxkufr3704ybirnrlrdouxd56f8 ON blc_product_tag(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idx3rml3ujsnmf0sm6i5pt2kqw1f ON blc_product_tag(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idxq0a4pa4gx7bxs45pmxhme3eea ON blc_product_tag(trk_catalog_context_id);
CREATE INDEX IF NOT EXISTS idxg1xhpljrql2eh84xhm384x6ym ON blc_product_tag(trk_parent_cat_context_id);
CREATE INDEX IF NOT EXISTS idxsoxnp92niuaof8g26tsyosn2i ON blc_product_tag(variant_id);
CREATE INDEX IF NOT EXISTS idxt6ag1nxbl2tbcqhwr3d75fvlf ON blc_product_tag(variant_id, product_context_id);
CREATE INDEX IF NOT EXISTS idxasl8ydc1h8r69pietosnndes5 ON blc_product_tag(variant_id, tag_context_id);
CREATE INDEX IF NOT EXISTS idx1wiv11del94fbkh22v5ms0ryn ON blc_promotional_category_product(context_id);
CREATE INDEX IF NOT EXISTS idx8cwyj4sit93x07bbbhib57a7r ON blc_promotional_category_product(promotional_product_context_id);
CREATE INDEX IF NOT EXISTS idx9alpxpjxudad8h6mns85vx448 ON blc_promotional_category_product(category_context_id);
CREATE INDEX IF NOT EXISTS idx46vh90r6jwj997op5ypat4afp ON blc_promotional_category_product(sorting);
CREATE INDEX IF NOT EXISTS idxcrbk5fyhi46emihoewnn6mh63 ON blc_promotional_category_product(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idxc1d6utkcqvms6bqc2htwynoxi ON blc_promotional_category_product(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idxkd9ycyhu8phssl7c3uep74kyc ON blc_promotional_category_product(trk_catalog_context_id);
CREATE INDEX IF NOT EXISTS idxobc5ac88j22essr8ummfvei2j ON blc_promotional_category_product(trk_parent_cat_context_id);
CREATE INDEX IF NOT EXISTS idx1362mnd0dxhntl4l4teoi82x3 ON blc_promotional_product(context_id);
CREATE INDEX IF NOT EXISTS idx1fxy5s5ljk76l4vgg5obgcsk9 ON blc_promotional_product(product_context_id);
CREATE INDEX IF NOT EXISTS idx7v76r2dcffxk29x6eif6grenh ON blc_promotional_product(related_product_context_id);
CREATE INDEX IF NOT EXISTS idxhxrme20ih956hsu5s5jpi5jbi ON blc_promotional_product(sorting);
CREATE INDEX IF NOT EXISTS idx51r0d7ski1tqw6v7k2o053246 ON blc_promotional_product(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idxrctbo2dkqnl0165jgwgb96n5i ON blc_promotional_product(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idxpld30whf717qdiaaomk86waqv ON blc_promotional_product(trk_catalog_context_id);
CREATE INDEX IF NOT EXISTS idxkglx74ww28nalyjo1xvccf9so ON blc_promotional_product(trk_parent_cat_context_id);
CREATE INDEX IF NOT EXISTS idxkm4y3qj3jh2mpt0rt6l6vscl8 ON blc_resource_lock(token);
CREATE INDEX IF NOT EXISTS idx4g14mrkab7tl3rd54ikx57k55 ON blc_translation(context_id);
CREATE INDEX IF NOT EXISTS idxgqgqttrr6uevhl0mjfwvfo4j1 ON blc_translation(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idxmttybtsh30xho30olqopnhs26 ON blc_translation(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idxhawx2xhnhqoqd7mct9qm7ces ON blc_translation(trk_catalog_context_id);
CREATE INDEX IF NOT EXISTS idxiwmmb8q1xtfycw8strr12ospk ON blc_translation(trk_parent_cat_context_id);
CREATE INDEX IF NOT EXISTS idxay3ff6dyxatoqm7lwxmualc9v ON blc_translation(trk_application_context_id);
CREATE INDEX IF NOT EXISTS idxh167c7f9ai480kx8gn7ww1f4h ON blc_translation(entity_type, entity_id, locale);
CREATE INDEX IF NOT EXISTS idxfs58rfg82kx9qhvjb8idlxxdo ON blc_translation(entity_type, entity_id, entity_field, locale);
CREATE INDEX IF NOT EXISTS idx35ojbgfk1ufqv2eictgob2jkf ON blc_variant(context_id);
CREATE INDEX IF NOT EXISTS idxb2gkxp7qm8fxdcqdyfr0nosu8 ON blc_variant(product_context_id);
CREATE INDEX IF NOT EXISTS idxo8jndbtv9sxsmuydfhs6r0gxl ON blc_variant(sku);
CREATE INDEX IF NOT EXISTS idx11gmghj1q04rr6hbl63fux3yl ON blc_variant(upc);
CREATE INDEX IF NOT EXISTS idxshsfh2cnbt0my7yh3hnm1wgro ON blc_variant(external_id);
CREATE INDEX IF NOT EXISTS idxmv9o3es70cl8np98njkoyakoj ON blc_variant(trk_sandbox_context_id);
CREATE INDEX IF NOT EXISTS idxawskuaem294a3ijchu5rubajw ON blc_variant(trk_sandbox_name);
CREATE INDEX IF NOT EXISTS idxmncwbq8twyl6x9vdpjg816xs8 ON blc_variant(trk_catalog_context_id);
CREATE INDEX IF NOT EXISTS idxruu99vko8fbojgq0sf1v7b6l0 ON blc_variant(trk_parent_cat_context_id);
CREATE INDEX IF NOT EXISTS fkqa2huaj7r3r8ovdilb9h71x2k_idx ON blc_catalog_ref(child_catalog_id);
CREATE INDEX IF NOT EXISTS idxjsrmtlej61uxhx0yiwpb2rcrv ON blc_notification_state(acked, stopped, notification_name, change_timestamp, next_attempt);
