Search code examples
sqloracle-databasejde

JDE how to convert F983051.VRPODATA (long / blob) to a string (varchar2)?


JDE how to convert F983051.VRPODATA (long / blob) to a string (varchar2)?

I'm not sure if I can do something like:

SELECT VRPID, VRVERS, FUNCTION(VRPODATA) FROM SCHEMA.F983051;

Where FUNCTION is something that converts the BLOB file into a varchar2.

P.d. I cannot use any kind of DDL.

Please advise,


Solution

  • I actually found what I wanted: DBMS_LOB.SUBSTR({BLOB field}).

    That field can help you for BLOB & HUGEBLOB data types, but it might not be able to recognize all of the values. It will substitute them with squares.

    Example:

    SELECT DBMS_LOB.SUBSTR({Huge Blob Field}) FROM {Table};
    

    If you can work with that, it's the way to go.

    Cheers.