From b29bfb6a91e0c69b351f00f9b27db183a4087820 Mon Sep 17 00:00:00 2001 From: eileen Date: Wed, 30 Dec 2020 16:22:37 +1300 Subject: [PATCH] Add index on civicrm_group.cache_date Per https://github.com/civicrm/civicrm-core/pull/19287 I also considered an index on refresh_date but I couldn't see any evidence the field is useful --- CRM/Contact/DAO/Group.php | 10 +++++++++- xml/schema/Contact/Group.xml | 5 +++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/CRM/Contact/DAO/Group.php b/CRM/Contact/DAO/Group.php index b57821d1deb2..417c467eb021 100644 --- a/CRM/Contact/DAO/Group.php +++ b/CRM/Contact/DAO/Group.php @@ -6,7 +6,7 @@ * * Generated from xml/schema/CRM/Contact/Group.xml * DO NOT EDIT. Generated by CRM_Core_CodeGen - * (GenCodeChecksum:3648ad60c504d25253ecc5655c629d72) + * (GenCodeChecksum:92977cbc500e10cef9399e66c0e63597) */ /** @@ -630,6 +630,14 @@ public static function &export($prefix = FALSE) { */ public static function indices($localize = TRUE) { $indices = [ + 'UI_cache_date' => [ + 'name' => 'UI_cache_date', + 'field' => [ + 0 => 'cache_date', + ], + 'localizable' => FALSE, + 'sig' => 'civicrm_group::0::cache_date', + ], 'index_group_type' => [ 'name' => 'index_group_type', 'field' => [ diff --git a/xml/schema/Contact/Group.xml b/xml/schema/Contact/Group.xml index 41948bbb39bd..e694a6a666a7 100644 --- a/xml/schema/Contact/Group.xml +++ b/xml/schema/Contact/Group.xml @@ -142,6 +142,11 @@ Date when we created the cache for a smart group 2.1 + + UI_cache_date + cache_date + 5.34 + refresh_date timestamp