Hi

Would it be better to have the field as a byte[], then write the object to
this array and the store it, instead of straight from Object to db

Håkon

2008/11/12 Håkon Sagehaug <[EMAIL PROTECTED]>

> hi
>
> So now I got a class that has a field that is of type java.lang.Object, I
> seems to go fine storing it, but when I want to retrieve the object from the
> db I get null.
>
> I use postgresql and tried with two tables one with datatype oid and one
> with bytea, but both returns null.
>
> Is this the right approach or is this wrong.
>
> any tips
>
> cheers, Håkon
>
> 2008/11/12 Håkon Sagehaug <[EMAIL PROTECTED]>
>
> Hi
>>
>> So what I got out of this is, if I've got a object asd type for a field I
>> can persist it but not query it for content, right?? That's fine for me.
>>
>> cheers, Håkon
>>
>>
>> 2008/11/11 Pinaki Poddar <[EMAIL PROTECTED]>
>>
>>
>>> Hi,
>>> Please refer [1] for different levels of support OpenJPA provides for
>>> relation fields whose types are not explicitly declared at design time.
>>>
>>> [1] http://openjpa.apache.org/builds/latest/docs/manual/manual.html#type
>>>
>>>
>>> --
>>> View this message in context:
>>> http://n2.nabble.com/Using-object-as-a-type-for-a-filed-in-a-enity-tp1485319p1485602.html
>>> Sent from the OpenJPA Users mailing list archive at Nabble.com.
>>>
>>>
>>
>>
>> --
>> Håkon Sagehaug, Software Developer
>> Parallab, Bergen Center for Computational Science (BCCS)
>> UNIFOB AS (University of Bergen Research Company)
>>
>
>
>
> --
> Håkon Sagehaug, Software Developer
> Parallab, Bergen Center for Computational Science (BCCS)
> UNIFOB AS (University of Bergen Research Company)
>



-- 
Håkon Sagehaug, Software Developer
Parallab, Bergen Center for Computational Science (BCCS)
UNIFOB AS (University of Bergen Research Company)

Reply via email to