[turba] Configure sources

Andreas Dahlen andreas at dahlen.ws
Tue May 17 07:01:48 PDT 2005


Hello!

I'm using Turba 2.0.2.

I'm trying to add a address book for the employees at our office.  The 
source isn't Horde based, without from our internal database.  I've 
configured sources.php as per "config from sources.php" (below).

I can't either search or browse or office-adress book. Localsql works 
fine. When I try to search on any of the search parameters (name, email 
or alias), I get the following error;
"DB Error: syntax error: SELECT ShortName FROM User WHERE  IN ('')"

I guess that the problem is that a fieldname is missing between "WHERE  
IN", but I can't figure out whats wrong.

Config from sources.php
$cfgSources['officesql'] = array(
    'title' => "Office",
    'type' => 'sql',
    'params' => array(
        'phptype' => 'mysql',
        'hostspec' => '****',
        'username' => '****',
        'password' => '****',
        'database' => 'intranet',
        'table' => 'User',
        'charset' => 'iso-8859-1'
    ),
    'map' => array(
        'name' => array('fields' => array('FirstName', 'LastName'),
                        'format' => '%s %s'),
        'email' => array('fields' => array('MailName', 'Domain'),
                        'format' => '%s %s),
        'alias' => 'ShortName'
    ),
    'search' => array(
        'name',
        'email',
        'alias'
    ),
    'strict' => array(
        'alias'
    ),
    'public' => true,
    'readonly' => true,
    'admin' => array(),
    'export' => true
);


/Andreas

----------------------------------------------------------------
This message was sent using IMP (http://www.horde.org).
Running on PHP 4.3.10, Apache 2.0.53, FreeBSD 5.3.



More information about the turba mailing list