cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Joseph <pjoseph...@yahoo.com>
Subject Re: how to persist a Collection property to postgresql using jdo
Date Sat, 09 Oct 2004 19:01:22 GMT
Thank you very much for the reply.  I think I
understand your method.

To simplify things however, I would like to save the
users selection as a column in the same table (parent)
and not in a separate table (child)

Thus the column will get data like [1,4] from the
multivalue widget, if the user chooses item ids 1,4 in
the multiselect.

The widget is using a set method in the fb:save that
sets a property that is a Java Collection.

My debug statments indicate it is trying to save
something like this [1,4] or [3,6,8] and so on.

so, to be more clear, I am trying to save a property
of type java.util.Collection in a column of table
Parent, in a postgresql db.  

thx
Paul
--- Joose Vettenranta <joose@iki.fi> wrote:

> >
> > Basic question is - how does on persist a
> collection
> > to a postrgest table using jdo?
> 
> Normally collection is just a 1:n connection to
> another table, like
> 
> create table parent (id integer);
> create table child (id integer, parent integer);
> 
> so you map parent to have collection Childs and then
> that Childs 
> collection you map to be of that child table.
> 
> - Joose
> 
> --
> "Always remember that you are unique, just like
> everyone else!"
> * http://iki.fi/joose/ * joose@iki.fi * +358 44 561
> 0270 *
> 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail:
> users-help@cocoon.apache.org
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message