CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Searching for contacts updated more than X days ago (from today)
Pages: [1]

Author Topic: Searching for contacts updated more than X days ago (from today)  (Read 345 times)

tv2011

  • I post occasionally
  • **
  • Posts: 51
  • Karma: 0
  • CiviCRM version: 4.5
  • CMS version: Drupal
  • MySQL version: 5
  • PHP version: 5
Searching for contacts updated more than X days ago (from today)
November 06, 2014, 02:28:24 am
Is it possible to create a custom search that shows all records which were last modified more than X days in the past, measured from today?

An Advanced search will let me search for records modified between two dates (but doesn't let me specific "today"), and will let me find records which *have* been modified in the last X months (but not ones which *haven't* been modified).

The search builder will let me use the "Modified date", but again won't let me select "Today" - it has to be a specific date.

Michael McAndrew

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1274
  • Karma: 55
    • Third Sector Design
  • CiviCRM version: various
  • CMS version: Nearly always Drupal
  • MySQL version: 5.5
  • PHP version: 5.3
Re: Searching for contacts updated more than X days ago (from today)
November 06, 2014, 02:46:36 am
Hey there,

Are you still on CiviCRM 2.1.1?  Might be time for an upgrade if so.

Quote
An Advanced search will let me search for records modified between two dates (but doesn't let me specific "today")

Later versions (I think 4.4+) have relative date fields in advanced search, so you can search for today, this week, etc.

There is a custom search that has been around for a while (and is in 2.1.1 as well, I am fairly sure) which allows you to search for contacts that are in some groups but not in others.  So you could accomplish this by creating a group for all contacts that have been modified in the last X months, and then doing a second search which excludes the aforementioned group.

Michael
Service providers: Grow your business, build your reputation and support CiviCRM. Become a partner today

tv2011

  • I post occasionally
  • **
  • Posts: 51
  • Karma: 0
  • CiviCRM version: 4.5
  • CMS version: Drupal
  • MySQL version: 5
  • PHP version: 5
Re: Searching for contacts updated more than X days ago (from today)
November 06, 2014, 02:59:08 am
Actually, I'm on 4.5 - thanks, I missed that in the advanced search.

So I think it's a bit of a workaround but your suggestion seems to work - thanks! And thanks for the very quick reply.

Michael McAndrew

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1274
  • Karma: 55
    • Third Sector Design
  • CiviCRM version: various
  • CMS version: Nearly always Drupal
  • MySQL version: 5.5
  • PHP version: 5.3
Re: Searching for contacts updated more than X days ago (from today)
November 06, 2014, 04:16:36 am
I asked because your profile says 2.1.1 - might want to update so people have a bit more info and can help you more easily :)
Service providers: Grow your business, build your reputation and support CiviCRM. Become a partner today

tv2011

  • I post occasionally
  • **
  • Posts: 51
  • Karma: 0
  • CiviCRM version: 4.5
  • CMS version: Drupal
  • MySQL version: 5
  • PHP version: 5
Re: Searching for contacts updated more than X days ago (from today)
November 06, 2014, 08:27:05 am
Done! Thanks - I'd forgotten about that.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Searching for contacts updated more than X days ago (from today)

This forum was archived on 2017-11-26.