From: Oliver M. B. <ol...@go...> - 2003-02-06 16:21:04
|
Hi! First of all, thanks to everybody for maintaining this great DBI package. I'm currently writing an Object Repository for Ruby (something similar to Java Data Objects) and want to use PostgeSQL's array types in order to save extra tables and the neccersary joins for simple lists. As it seems, DBD::Pg, has no support for Arrays and returns such values as Strings in PostgreSQL's escaping (INT[] becomes "{ 1,2,3}", VARCHAR(x)[] becomes "{foo,bar}" ). Of course I could parse them myself, but has anybody already done work adding support for Arrays to DBD::Pg ? If I was to do it, where should I start ? A really quick glance into DBD::Pg shows that the type conversion is done according to type_map and the type of a column according to pg_result.type For example BIGINT[] gives type 1016, VARCHAR(255)[] gives 1015 as type on my system, but they are not contained in type_map, so they are converted to String.... -- Oliver M. Bolzer ol...@go... GPG (PGP) Fingerprint = 621B 52F6 2AC1 36DB 8761 018F 8786 87AD EF50 D1FF |