Re: Archive Old Data to Different DB ... ?
Hey there!
There are probably more elegant solutions, but I'd probably use a simple set of SQL commands to perform the sync. This sounds like a one-way sync, so you'll need to identify which tables you want backed up, then simply filter against the date_modified (or date_created) fields. Note that you should pay attention to <table>_cstm tables (which contain custom field information, if you've defined any custom fields for a module), plus the dozens of relationship tables.
For example, if you just wanted to sync the Contacts module, you'd probably need to pull from all these tables:
accounts_contacts
calls_contacts
contacts
contacts_audit
contacts_bugs
contacts_cases
contacts_cstm
contacts_users
email_addr_bean_rel
email_addresses
emails_beans
emails_email_addr_rel
fields_meta_data
meetings_contacts
opportunities_contacts
...etc...
Note that just about all these tables, even the link tables, have a date_modified field that you can filter against. Let us know what you come up with!
Julian Ostrow
Systems and Applications Engineer
SugarCRM Inc.
Bookmarks