Advertisement
matthewpoer

SugarCRM database wipe

Jan 23rd, 2013
227
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MySQL 8.46 KB | None | 0 0
  1. delete from accounts;
  2. delete from accounts_audit;
  3. delete from accounts_bugs;
  4. delete from accounts_cases;
  5. delete from accounts_contacts;
  6. delete from accounts_cstm;
  7. delete from accounts_opportunities;
  8. delete from acl_actions;
  9. delete from acl_fields;
  10. delete from acl_roles;
  11. delete from acl_roles_actions;
  12. delete from acl_roles_users;
  13. delete from address_book;
  14. delete from address_book_list_items;
  15. delete from address_book_lists;
  16. delete from bugs;
  17. delete from bugs_audit;
  18. delete from calls;
  19. delete from calls_contacts;
  20. delete from calls_leads;
  21. delete from calls_users;
  22. delete from campaign_log;
  23. delete from campaign_trkrs;
  24. delete from campaigns;
  25. delete from campaigns_audit;
  26. delete from cases;
  27. delete from cases_audit;
  28. delete from cases_bugs;
  29. delete from cases_cstm;
  30. delete from category_tree;
  31. -- delete from config;
  32. delete from contacts;
  33. delete from contacts_audit;
  34. delete from contacts_bugs;
  35. delete from contacts_cases;
  36. delete from contacts_cstm;
  37. delete from contacts_users;
  38. delete from contract_types;
  39. delete from contracts;
  40. delete from contracts_audit;
  41. delete from contracts_contacts;
  42. delete from contracts_opportunities;
  43. delete from contracts_products;
  44. delete from contracts_quotes;
  45. delete from currencies;
  46. delete from custom_fields;
  47. delete from document_revisions;
  48. delete from documents;
  49. delete from documents_accounts;
  50. delete from documents_bugs;
  51. delete from documents_cases;
  52. delete from documents_contacts;
  53. delete from documents_opportunities;
  54. delete from documents_products;
  55. delete from documents_quotes;
  56. delete from eapm;
  57. delete from email_addr_bean_rel;
  58. delete from email_addresses;
  59. delete from email_cache;
  60. delete from email_marketing;
  61. delete from email_marketing_prospect_lists;
  62. delete from email_templates;
  63. delete from emailman;
  64. delete from emails;
  65. delete from emails_beans;
  66. delete from emails_email_addr_rel;
  67. delete from emails_text;
  68. -- delete from expressions;
  69. -- delete from fields_meta_data;
  70. delete from folders;
  71. delete from folders_rel;
  72. delete from folders_subscriptions;
  73. delete from forecast_schedule;
  74. delete from forecasts;
  75. delete from fts_queue;
  76. delete from holidays;
  77. delete from import_maps;
  78. delete from inbound_email;
  79. delete from inbound_email_autoreply;
  80. delete from inbound_email_cache_ts;
  81. delete from jjwg_address_cache;
  82. delete from jjwg_address_cache_audit;
  83. delete from jjwg_areas;
  84. delete from jjwg_areas_audit;
  85. delete from jjwg_maps;
  86. delete from jjwg_maps_audit;
  87. delete from jjwg_maps_jjwg_areas_c;
  88. delete from jjwg_maps_jjwg_markers_c;
  89. delete from jjwg_markers;
  90. delete from jjwg_markers_audit;
  91. delete from job_queue;
  92. delete from kbcontents;
  93. delete from kbcontents_audit;
  94. delete from kbdocument_revisions;
  95. delete from kbdocuments;
  96. delete from kbdocuments_kbtags;
  97. delete from kbdocuments_views_ratings;
  98. delete from kbtags;
  99. delete from leads;
  100. delete from leads_audit;
  101. delete from leads_cstm;
  102. delete from linked_documents;
  103. delete from manufacturers;
  104. delete from meetings;
  105. delete from meetings_contacts;
  106. delete from meetings_leads;
  107. delete from meetings_users;
  108. delete from notes;
  109. delete from notes_cstm;
  110. delete from notifications;
  111. delete from notifications_audit;
  112. delete from oauth_consumer;
  113. delete from oauth_nonce;
  114. delete from oauth_tokens;
  115. delete from opportunities;
  116. delete from opportunities_audit;
  117. delete from opportunities_contacts;
  118. delete from opportunities_cstm;
  119. delete from outbound_email;
  120. delete from product_bundle_note;
  121. delete from product_bundle_notes;
  122. delete from product_bundle_product;
  123. delete from product_bundle_quote;
  124. delete from product_bundles;
  125. delete from product_categories;
  126. delete from product_product;
  127. delete from product_templates;
  128. delete from product_types;
  129. delete from products;
  130. delete from products_audit;
  131. delete from project;
  132. delete from project_cstm;
  133. delete from project_resources;
  134. delete from project_task;
  135. delete from project_task_audit;
  136. delete from projects_accounts;
  137. delete from projects_bugs;
  138. delete from projects_cases;
  139. delete from projects_contacts;
  140. delete from projects_opportunities;
  141. delete from projects_products;
  142. delete from projects_quotes;
  143. delete from prospect_list_campaigns;
  144. delete from prospect_lists;
  145. delete from prospect_lists_prospects;
  146. delete from prospects;
  147. delete from quotas;
  148. delete from quotes;
  149. delete from quotes_accounts;
  150. delete from quotes_audit;
  151. delete from quotes_contacts;
  152. delete from quotes_opportunities;
  153. delete from relationships;
  154. delete from releases;
  155. delete from report_cache;
  156. delete from report_schedules;
  157. delete from roles;
  158. delete from roles_modules;
  159. delete from roles_users;
  160. delete from saved_reports;
  161. delete from saved_search;
  162. delete from schedulers;
  163. delete from schedulers_times;
  164. delete from session_active;
  165. delete from session_history;
  166. delete from shippers;
  167. delete from sugarfavorites;
  168. delete from sugarfeed;
  169. -- delete from systems;
  170. delete from tasks;
  171. delete from taxrates;
  172. delete from team_memberships;
  173. delete from team_notices;
  174. delete from team_sets;
  175. delete from team_sets_modules;
  176. delete from team_sets_teams;
  177. delete from teams;
  178. delete from timeperiods;
  179. delete from tracker;
  180. delete from tracker_perf;
  181. delete from tracker_queries;
  182. delete from tracker_sessions;
  183. delete from tracker_tracker_queries;
  184. delete from upgrade_history;
  185. delete from user_preferences;
  186. delete from users;
  187. delete from users_feeds;
  188. delete from users_holidays;
  189. delete from users_last_import;
  190. delete from users_password_link;
  191. delete from users_signatures;
  192. delete from vcals;
  193. -- delete from versions;
  194. delete from workflow;
  195. delete from workflow_actions;
  196. delete from workflow_actionshells;
  197. delete from workflow_alerts;
  198. delete from workflow_alertshells;
  199. delete from workflow_schedules;
  200. delete from workflow_triggershells;
  201. delete from worksheet;
  202.  
  203. insert into users (id,user_name,user_hash,sugar_login,is_admin,status,default_team,team_set_id,show_on_employees,employee_status) VALUES ('1','admin','21232f297a57a5a743894a0e4a801fc3',1,1,'Active',1,1,1,'Active');
  204.  
  205. INSERT INTO `email_templates` (`team_id`,`team_set_id`,`id`,`date_entered`,`date_modified`,`modified_user_id`,`created_by`,`published`,`name`,`description`,`subject`,`body`,`body_html`,`deleted`,`assigned_user_id`,`base_module`,`from_name`,`from_address`,`text_only`,`type`) VALUES ('d5016ab0-8c43-958d-b09a-4f738f313778','d5016ab0-8c43-958d-b09a-4f738f313778','9f7d9723-3cba-c25a-3c66-4f738f6b9487','2012-03-28 22:23:32','2012-03-28 22:23:32','1','1','off','Forgot Password email','This template is used to send a user a link to click to reset the user''s account password.','Reset your account password','
  206. You recently requested on $contact_user_pwd_last_changed to be able to reset your account password.
  207.  
  208. Click on the link below to reset your password:
  209.  
  210. $contact_user_link_guid','<div><table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width="550" align=\"\"\"center\"\"\"><tbody><tr><td colspan=\"2\"><p>You recently requested on $contact_user_pwd_last_changed to be able to reset your account password. </p><p>Click on the link below to reset your password:</p><p> $contact_user_link_guid </p>  </td>         </tr><tr><td colspan=\"2\"></td>         </tr> </tbody></table> </div>',0,NULL,NULL,NULL,NULL,0,NULL);
  211. INSERT INTO `email_templates` (`team_id`,`team_set_id`,`id`,`date_entered`,`date_modified`,`modified_user_id`,`created_by`,`published`,`name`,`description`,`subject`,`body`,`body_html`,`deleted`,`assigned_user_id`,`base_module`,`from_name`,`from_address`,`text_only`,`type`) VALUES ('d5016ab0-8c43-958d-b09a-4f738f313778','d5016ab0-8c43-958d-b09a-4f738f313778','9ae24cb3-5f85-b989-089f-4f738f3d0e17','2012-03-28 22:23:32','2012-03-28 22:23:32','1','1','off','System-generated password email','This template is used when the System Administrator sends a new password to a user.','New account information','
  212. Here is your account username and temporary password:
  213. Username : $contact_user_user_name
  214. Password : $contact_user_user_hash
  215.  
  216. $config_site_url
  217.  
  218. After you log in using the above password, you may be required to reset the password to one of your own choice.','<div><table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width="550" align=\"\"\"center\"\"\"><tbody><tr><td colspan=\"2\"><p>Here is your account username and temporary password:</p><p>Username : $contact_user_user_name </p><p>Password : $contact_user_user_hash </p><br><p>$config_site_url</p><br><p>After you log in using the above password, you may be required to reset the password to one of your own choice.</p>   </td>         </tr><tr><td colspan=\"2\"></td>         </tr> </tbody></table> </div>',0,NULL,NULL,NULL,NULL,0,NULL);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement