Angus Lees wrote:
> 
> just started using DBIx::Recordset Links with PostgreSQL and ran
> into a few problems:
> 
> DBIx::Compat gives SupportSQLJoin => 0 for Pg.
> PostgreSQL 7.1 (at least) claims to fully support joins.
> 
> DBIx::Recordset::BuildFields() has explicit code for SupportSQLJoin = (1..3),
> but the "else" clause here builds statements like:
> 
>   SELECT <fields> FROM table1,OUTER table2 ,OUTER table3 WHERE ...
> 
> which (as far as i can work out), is not valid SQL. (I presume this is
> supposed to be "LEFT OUTER"? i've never used sql joins before.)
> 
> this, combined with above SupportSQLJoin=0, makes Links unusable with Pg :(
> 
> there is no code (or documentation) for SupportSQLJoin = 4, which Informix
> claims to have.


Postgres has supported joins for a year or so, I planed to patch Compat
sooner or later but I didn't really need joins until now - but if you
add it, I'll probably use it ;-). But linked tables work OK even now:

$db = DBIx::Database->new({
        '!DataSource' => "DBI:Pg:dbname=phl",
        '!Username' => 'postgres',
        '!DBIAttr' => { RaiseError => 1, AutoCommit => 0 },
        '!DoOnConnect' => [ qq(SET CLIENT_ENCODING TO 'win1250'), qq(SET
DATESTYLE TO 'german') ],
        '!KeepOpen' => 1,
});

*hotels = DBIx::Recordset->Setup({
        '!DataSource' => $db,
        '!Table' => 'hotels,descriptions',
        '!TabRelation' => 'hotels.id = descriptions.id',
});

- Robert

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to