[turba] keep turba in sync with employees DB
Michael Rubinsky
mrubinsk at horde.org
Thu Jun 18 14:39:43 UTC 2009
Quoting Andreas Moroder <andreas.moroder at sb-brixen.it>:
> Hello,
>
> we have a oracle DB with data about our employees that include
> phonenumber and mail. We would like to keep the turba address book (
> postgres ) in sync with this oracle DB using a perl script that
> should be called by cron every night.
>
> Is there documentation on how turba stores the data in in the
> postgres tables the way we can access them via DBD:pg or is there a
> simple API ?
Turba has methods such search, getContact, replace, and import that
could be used for something like this. However, if what your doing is
simply updating a few fields of existing contacts, it might be easier
for you to modify the turba_objects table directly. Most of the fields
in the turba_objects table are self explanatory. Some that might not
be include the object_id - a locally unique identifier, object_uid - a
globally unique identifier used mostly for syncing, owner_id - this is
either the username of the owner of the contact (if not using a shared
source) or the id of the share that represents the address book this
contact belongs to, object_type would always be "Object" for a
contact, object_members is only used when the entry defines a contact
group and contains a serialized hash of the contact ids that it
contains.
HTH
Thanks,
mike
--
The Horde Project (www.horde.org)
mrubinsk at horde.org
"Time just hates me. That's why it made me an adult." - Josh Joplin
More information about the turba
mailing list