[Dbix-class] How to use arrays in database

Dami Laurent (PJ) laurent.dami at justice.ge.ch
Mon May 26 16:04:33 BST 2008


>-----Message d'origine-----
>De : Lee Standen [mailto:nom at standen.id.au] 
>Envoyé : dimanche, 25. mai 2008 07:02
>À : jt at toerring.de; Class user and developer list
>Objet : Re: [Dbix-class] How to use arrays in database
>
>The problem, I think you'll find, is that the ARRAY columns 
>supported by 
>Postgres are very specific to Postgres.  I've not seen support for an 
>array data type in any other database, and a quick google seems to 
>confirm that it's a very Postgres specific feature.
>
>If you need to store an array in a column, then you probably need to 
>rethink your schema...
>

Just for info, the Livelink Collection Server (formerly known as Basis+) database also has something like arrays : every column definition has an "OCCURS" range with minimal and maximal number of values.

In my organization this has been used for 20 years for classification purposes (storing a collection of keywords associated with a record) and also for storing multi-line data, like addresses. Granted, this mechanism breaks the purely relational model, but it also has a number of advantages in some situations.

There seems to be a number of other databases that also support multivalues : see http://l.webring.com/hub?ring=mvring

Best regards, Laurent Dami




More information about the DBIx-Class mailing list