On 9/5/07, Karr, David <dav...@wa...> wrote:
> Is it possible to use SQuirreL to insert a large value (> 4000 chars)
> into a clob column in Oracle? I apparently have my table and column
> configured to accept larger values, but apparently using a literal value
> of > 4000 chars won't work.
>
> My actual application will use Hibernate and PreparedStatements, but I
> need to prototype this strategy first in a SQL browser.
David,
You can import a file using the popup window when double-clicking on
an editable CLOB cell in the contents tab. It will allow you to
specify a file , then import it into the popup dialog and finally
Update the table cell. One catch though - the code uses a pre-Java1.4
algorithm which seems to be very slow at the moment. So, I tried a
2MB text file and waited about two minutes before bailing. The code
has a comment that Gerd rightfully placed there to use the
String.replaceAll method instead - I was able to import the same 2MB
file in about 3-4 secs after making the change. Now that we require
1.5 as the minimum version I see no reason to keep this slower code.
So, I'll post the fix to the trunk and it will be available in the
next snapshot build. You may still be able to use whatever version
you currently have if the file is small-ish - which it sounds like
yours could be < 8K.
Rob
|