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 (Moderator: Dave Greenberg) »
  • Is there a "Purge All"?
Pages: [1]

Author Topic: Is there a "Purge All"?  (Read 794 times)

corster

  • I post occasionally
  • **
  • Posts: 72
  • Karma: 0
  • CiviCRM version: CiviCRM 4.0.x
  • CMS version: Joomla 1.7.x
Is there a "Purge All"?
January 25, 2011, 08:00:16 am
Hello,


We have a great start on our new site, but in learning on CiviCRM works, we have made some import mistakes.  Is there a way to purge all Contact Records without effecting all of the custom fields, profiles, and other configurations we have done?


Thanks,

Curtis
Curtis

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Is there a "Purge All"?
January 25, 2011, 08:42:17 am

No purge all, but should be a relatively simple php/sql script to delete all data in a consistent order

If you do write it, please publish your code so others can benefit

thanx

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

CiviTeacher.com

  • I live on this forum
  • *****
  • Posts: 1282
  • Karma: 118
    • CiviTeacher
  • CiviCRM version: 3.4 - 4.5
  • CMS version: Drupal 6&7, Wordpress
  • MySQL version: 5.1 - 5.5
  • PHP version: 5.2 - 5.4
Re: Is there a "Purge All"?
January 27, 2011, 08:46:49 pm
If your only goal is to delete all Contacts in the database, and you don't care if new Contact IDs start over at #1 (Contact id #1) again, then this is easily done with core CiviCRM funtionality.

1. Go to "Find Contacts"
2. Do not enter any search criteria, simple click the button
3. The result should be ALL the contacts in your database, regardless of type
4. Click "All contacts" on the results page.
5. Choose "Delete Permanently" from the options menu
6. Click Go.

All your Contact's data will be gone, but the structure you have created, with Custom fields and Profiles, will still exist.   They will just be empty.

It goes without saying (I hope) that a backup before taking this drastic action is necessary.





Try CiviTeacher: the online video tutorial CiviCRM learning library.

corster

  • I post occasionally
  • **
  • Posts: 72
  • Karma: 0
  • CiviCRM version: CiviCRM 4.0.x
  • CMS version: Joomla 1.7.x
Re: Is there a "Purge All"?
January 28, 2011, 11:58:22 am
Thank you Stoob,


I semi-overlooked this.  I believe this will get us what we need/want.


Thanks again!

Curtis
Curtis

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM (Moderator: Dave Greenberg) »
  • Is there a "Purge All"?

This forum was archived on 2017-11-26.