#436 Copying LOBs from Oracle to Oracle fails

2.3final
closed-fixed
5
2006-10-25
2006-10-25
Rob Manning
No

When a table has data that includes a CLOB/BLOB column,
the copy operation fails (unknown column type). The
root problem is that the Oracle JDBC driver reports
CLOB/BLOB columns to have type 1111 (OTHER), when
it should report them as java.sql.Types.BLOB/CLOB
(2004/2005). There is already code to work-around
this problem, but it only addresses the scenario
where Oracle is the source database. If Oracle is
the destination database and the field type is
BLOB/CLOB the copy operation will fail.

Discussion

  • Rob Manning

    Rob Manning - 2006-10-25

    Logged In: YES
    user_id=1287991

    Fixed in CVS. The algorthim is:

    If destination column type is Types.OTHER (1111), try to get
    the type name and map it to a valid java SQL type (such as
    Types.BLOB or Types.CLOB). This only works when the
    database column
    type name as reported by the JDBC driver is a standard type
    such as
    BLOB, VARCHAR, CLOB, CHAR, etc... A mapping exception is thrown
    otherwise.

     
  • Rob Manning

    Rob Manning - 2006-10-25
    • status: open --> closed-fixed
     

Log in to post a comment.