db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jim Schneider <jschnei...@kjinteractive.com>
Subject Re: LOBs, Torque, Oracle > 4K data
Date Tue, 25 Feb 2003 13:54:34 GMT
I set my column type in my torque schema file (*.xml) to 
"LONGVARBINARY". Torque converts this type to a LONG RAW column type in 
my oracle schema file (*.sql). In the generated om classes, this is 
translated to a byte array (byte[]) in my data objects, which all seems 
fine to me.

However, when I go to insert my files (image file > 4K), I get the 
following exception (my file is 5677 bytes):

"org.apache.torque.TorqueException: Data size bigger than max size for 
this type: 5677"

When I insert a file smaller than 4K, I don't get the error.

Do I need to (or can I) specify a max size for the column?

Thanks for the response,

Jim

Bill Schneider wrote:

>"LONGVARBINARY" is the JDBC type.  You want to use the "LONG RAW" type in
>Oracle which does not have a 4K limit.
>
>-- Bill
>----- Original Message -----
>From: "Jim Schneider" <jschneider@kjinteractive.com>
>To: "Turbine Torque Users List" <torque-user@db.apache.org>
>Sent: Tuesday, February 25, 2003 7:16 AM
>Subject: Re: LOBs, Torque, Oracle > 4K data
>
>
>  
>
>>Yes, soryy, that is happening with me too. At the time, I was only
>>concerned with the insert/update. When I changed the "type" to
>>LONGVARBINARY, all is well except for the 4K limit. Any way to get
>>around this with Torque?? How have other people solved this problem?
>>
>>Thx,
>>
>>Jim
>>
>>Geoff Fortytwo wrote:
>>
>>    
>>
>>>You can use BLOBs in torque with oracle? AFAIK, everyone else just
>>>gets null returned when they use CLOBs or BLOBs in torque with an
>>>oracle driver.
>>>
>>>At 04:10 PM 2/24/2003, Jim Schneider wrote:
>>>
>>>      
>>>
>>>>What is the preferred method (Torque data type) for LOBs that are > 4K?
>>>>
>>>>If I use BLOB with a file that is smaller than 4K, everything is
>>>>fine. With > 4K, I get an error indicating that the size is too big.
>>>>
>>>>Thanks in advance.
>>>>
>>>>Jim
>>>>
>>>>
>>>>--
>>>>Jim Schneider
>>>>KJ Interactive, Inc.
>>>>303-765-1357
>>>>www.kjinteractive.com
>>>>
>>>>
>>>>
>>>>
>>>>---------------------------------------------------------------------
>>>>To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
>>>>For additional commands, e-mail: torque-user-help@db.apache.org
>>>>        
>>>>
>>>
>>>---------------------------------------------------------------------
>>>To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
>>>For additional commands, e-mail: torque-user-help@db.apache.org
>>>
>>>
>>>      
>>>
>>--
>>Jim Schneider
>>KJ Interactive, Inc.
>>303-765-1357
>>www.kjinteractive.com
>>
>>
>>
>>
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
>>For additional commands, e-mail: torque-user-help@db.apache.org
>>
>>    
>>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
>For additional commands, e-mail: torque-user-help@db.apache.org
>
>
>  
>

-- 
Jim Schneider
KJ Interactive, Inc.
303-765-1357
www.kjinteractive.com



Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message