Thunderbird Google Postal Address sync - Part Two

Today’s testing release introduces a feature to sync postal addresses between Thunderbird and Google.

An earlier blog entry on postal addresses began by noting the underlying difficulty of syncing Thunderbird and Google postal addresses because:

  • Thunderbird structures a postal address into several fields: street, city, state, postcode and country; whereas
  • Google has one free-format “postal address” field

Here’s how the postal address sync feature works.

The Zindus/Preferences/Advanced button opens a window which allows you to enable postal address sync. By default the feature is disabled.

Sync Google Postal Address

Once the feature is enabled, the next sync is a slow sync, in which each postal address in a Thunderbird contact is encoded as XML and written to the address field of the Google contact. Any text in the Google field is preserved in the <otheraddr> element.

Before

Thunderbird Address Fields       Google Address Field
==========================       ====================
1 Example st                     a free-format address
Melbourne
Australia

After

Thunderbird Address Fields       Google Address Field
==========================       ====================
                                 <address>
1 Example st                     <street> 1 Example st </street>
Melbourne                        <city> Melbourne </city>
Australia                        <country> Australia </country>
                                 <otheraddr> a free-format address </otheraddr>
                                 </address>

This is a full two-way sync, so you can edit the XML in Google and see the changes in Thunderbird.

If you try this feature and don’t like it you can turn it off. The next sync after the feature is disabled is a slow sync in which the process described above is reversed. The XML that the addon introduced into the Google address field is removed. The text that had been preserved in the <otheraddr> element is restored.

Here are some reasons why you might not want to use this feature:

  • you don’t like looking at XML in Gmail because it’s ugly,
  • you find that the Google Maps button in Gmail doesn’t work because Google Maps doesn’t understand XML
  • you notice that if you edit the XML in Google and break the XML syntax, the addon thinks that the XML has been removed from Google, and the address parts of the Thunderbird contact are deleted!

We realise this feature isn’t for everyone. That’s why it’s disabled by default. This feature is being introduced because the response to the earlier blog post on postal addresses made it clear that some users really want their Thunderbird postal addresses synced with Google! Despite it’s limitations, the approach described here is better than nothing, and as the person who first emailed in asking for something to be done wrote:

The spirit is: given that comprehensive synchronization is impossible, please give me a way to see the addresses of my Thunderbird contact list in Gmail.

If you’d like to do some more reading on postal addresses in Google and Thunderbird, here’s some references:

  • a discussion thread on the Google Contacts API developers list. A developer there suggested using Google’s geocoding API to match postal address formats. An excellent idea but unfortunately the Google Maps terms of service don’t allow it.

Google hadn’t contributed to that discussion at the time of this writing.

  • a discussion thread on the Thunderbird developers list looking at changes to the handling of postal address for Thunderbird 3.

Happy syncing!

If you liked this Blog, share the love :                    

12 Responses to “Thunderbird Google Postal Address sync - Part Two”

  1. Markus Says:

    The XML won’t be to everyone’s taste but it works for me - thanks!

  2. carl Says:

    I agree. For those who really need it, this sync solution seemes to be ok for now (I think I will leave it disabled at the moment). Let’s hope google will make a more elegant solution soon.

    This zindus extension is really promising. Now I really hope support for google contact groups ( thunderbird contact lists) will be implemented. Keep up the good work!

  3. Zindus » Blog Archive » zimbra.free.fr Says:

    […] For Google users, this release includes an optional feature to sync postal addresses. […]

  4. Pete Says:

    Are there plans to implement sync between Google Groups and Thunderbird Lists?

    I can’t tell you how useful this feature would be to me.

    Cheers

  5. leni Says:

    @Pete - yes, Google Groups will eventually sync with Thunderbird mailing lists. The current plan is that this feature will co-incide with release of Thunderbird 3. See the roadmap.

  6. 56ksurfer Says:

    What about syncing the thunderbird address fields into the google address field?
    In a fix or maybe user defined format. for example:

    thunderbird
    -street: Example st
    -number: 1
    -postcode: 12345
    -town: Melbourne
    -country: Australia

    == > into ==>

    Google freeform field:
    Example st 1
    12345 Melbourne
    Australia

    if every syncclient a person uses does the same it works fine. That would be cool to sync with the iphone. which does it like in the example above.

  7. 56ksurfer Says:

    .. correction: iphone does not sync it. nuevasync.com does it this way!

  8. Olli Says:

    Even if the proposal of 56ksurfer is not synchronized with the iphone or other mobile phones, I would realy like to have a “human readable” address on google side. You could realize this as an option.

    That would be a great feature!

    If someone add address text which is not conform to this syntax on the google side, he should live with wrong synchronization.

    Another possibility (or option) would be to synchronize address fields only from Thunderbird -> Goggle and not vice versa.

    Thanks for your great work!

  9. frombrosis Says:

    Keep up the good work Zindus people! It’s really frustrating to think in 2008 we still can’t something as simple as a unified address book system. Sure there is to some extent “standardisation” however, in all honesty, we shouldn’t *need* Zindus in the first place to keep things in sync.

    Anyway, this solution is not for me unfortunately, as I want to keep my Gmail contact list neat and tidy… A real shame, hopefully Google one day allow for more fields in their postal address contact system.

  10. fnog Says:

    I second an option for one-way synchronizing Thunderbird into Google contacts. As for me, google is the mediator from which I sync office, home, mobile phone and ipod touch as well as portable USB software, I would find it prudent to go with the more advanced storage format (thunderbird), sync this to google as human-readable text, which will then forward this to handheld devices via nuevasync or somesuch…

    also, what about a solution that used a fixed-format approach, for example a comma delimited approach which would simply leave missing fields empty, ie:

    using the above example:
    thunderbird
    -street/Address: Rudolfstraße 1
    -postcode: 8010
    -town: Graz
    -State/Province:
    -country: Austria

    with syntax , , , ,
    to google:

    Rudolfstraße 130, 8010, Graz, , Austria

    this also correctly parses in google maps and might be snychable back to thunderbird if empty fields simply produce an extra comma.

  11. matze Says:

    I tried to use the XML format for postal adress and coudn’t find the schema file for the given ULR: http://schemas.zindus.com/sync/2008. Maybe it’s just a broken link.

    By the way: it is just a horrible theme.

  12. leni Says:

    matze - the schema file doesn’t exist. That’s pretty normal - see wikipedia. The reason it’s there is to distinguish format versions if/when Thunderbird’s postal address fields change.

    A new theme is on the todo list :-)

Leave a Reply