I've got an Address Book Archive (.abbu) file that I backed up a while ago. For some reason some of my contacts got deleted, and I know they're in this backup. I have also changed and added some contacts since the backup (about 4 months ago). I'd like to know if there's a way to open up this archive without replacing all of my contacts and then maybe somehow compare the two address books to see what contacts I need to carry over.
2 Answers
An .abbu
backup is all-or-nothing. vCard exports are not. Here's the approach I would take:
- Select all your contacts
- File > Export > vCard > Export vCard…
- Save it somewhere.
- File > Import… your old .abbu archive, replacing everything
- File > Import… your previously saved vCard archive
- Address book will now allow you update your old archive with your new vCard information. You will have the option to Review Duplicates…
PS. Just to be safe, i'd also export a new .abbu
archive first (not replacing the old one) just in case there are some vCard quirks I'm not aware of and you've mucked things up. ;-)
I know this topic is old but I think this might help to future user inquiries.
I basically start as ghoppe:
To identify the changes on the Contacts DB respect to a previous backup:
- Do "File > Export > Address Book Archive..." (to have a good backup)
- Select all your contacts and do "File > Export > Export vCard". Save this in after.vcf
- File > Import… your old .abbu archive, replacing everything.
- Select all your contacts and do "File > Export > Export vCard". Save this in before.vcf
Open a shell and execute the following line:
diff after.vcf before.vcf | egrep "(<|>) N:" | sort -k 2 | uniq -c -i -s 2 | tee dif.txt | wc -l && cat dif.txt
This will first list a line indicating the number of distinct records (e.g., after a "Remove Duplicates") and then the list of the entry names of those records (each line preceded by the number of repetitions of that line). E.g.:
2
4 < N:John Smith;;;
3 < N:Cath Jones;;;
It means two different names, four repetitions of the first one and three repetitions of the last one.
I hope this help. Certainly it helped me to identify what cards where merged when looking for duplicates.