db-ddlutils-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexandre Borgoltz <alexandre.borgo...@smartjog.com>
Subject Re: Stream already closed
Date Wed, 12 Oct 2005 10:39:38 GMT
 >The other reason why this is happening, might be that the column in
 >question is a LONG column which is known to give problems with Oracle
 >JDBC drivers, especially the thin driver.

You seem to be right, Tom.
My tests proved that resultset.getString("COLUMN_DEF") :
+can't be called twice (if .next() is not called obviously)
+always fails for primary fields with 9i- drivers
+fails if called after e.g. .getString("IS_NULLABLE") with 10g drivers
+works OK if called first *with 10g drivers*

So what I did is modify
JdbcModelReader.getColumnsForTable(DatabaseMetaData, String)
and move the call of
getValueAsString(..., "COLUMN_DEF", ...)
to be the first one called. This works perfectly on my platform now.

I have included the corresponding patch. You can of course do whatever 
you want with it, provided I am responsible for nothing :P
Do you think this will have side effects? Can I use DdlUtils that way 
safely?

HTH & TIA,

Alexandre BORGOLTZ
Head of Technology

SmartJog SA
Phone: +33 (0)1 4996 6324
Fax: +33 (0)1 4996 6405
Mobile: +33 (0)6 8882 1417
alexandre.borgoltz@smartjog.com


Mime
View raw message