2

On CiviCRM 5.6.0

I have a Smart Group based upon custom_param1=1 (as an example).

I change some values of custom_param1, to update my Smart Group in order to send a mail to its updated members.

But the Smart Group is not updated immediately (I have to wait 5 minutes before it is)

How can I force its update to have it immediately ?

(rebuilding the smart group cache has no effect)

3 Answers 3

1

Clearing the Civi cache doesn't work? It should.

3
  • can you run cron faster?
    – Sean Kenny
    Nov 19, 2018 at 16:38
  • @Andy : I did not expect cleaning the civi cache would work (while rebuilding the smart group cache does not), but actually, you look right ; I will test more extensively. BTW, do you know how I can clean the cache from a php program (I am not really a programmer, but may be able to with a little help) ? Nov 19, 2018 at 16:38
  • @Sean : running CRON has no effect Nov 19, 2018 at 16:40
1

Change the 'Smart group cache timeout' which is in Administer/Customise data and screens/Search Preferences The default is 5 minutes but I normally set this to 1 for my clients. It can be set to zero but this isn't recommended according to this screen.

1

Instead of openning the Smart Group (e.g. /civicrm/group/search?force=1&context=smog&gid=341&component_mode=1), you can call its pertaining Search (e.g. /civicrm/contact/search/advanced?reset=1&force=1&ssID=263).

You can get the Search Id (ssID) :

  • either via "Edit Smart Group Searc Criteria ..." button (which calls the associated Search URL)
  • or in the civicrm_group table : saved_search_id field

NO : this gives erratic results

1
  • if your last edit means 'this answer does not work' then perhaps it should be deleted as an Answer and added as a Comment or an 'update' on the Question.
    – petednz - fuzion
    Jan 6, 2019 at 22:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.