Home > database >  Oracle database hexadecimal String Blob
Oracle database hexadecimal String Blob

Time:09-20

RT, the library is the hexadecimal value of the type of BLOB, object defined in the type String is received, the bosses excuse me, how to turn?

CodePudding user response:

First to determine whether a blob data is empty, and then USES the input stream to read data
 
The String content=null;
Try {

If (image!=null) {
InputStream is=image. GetBinaryStream ();
Byte [] b=new byte [is available ()];
Is. Read (b, 0, b.l ength);
The content=new String (b);
}
System. The out. Println (content);
} the catch (IOException e) {
e.printStackTrace();
}

CodePudding user response:

reference 1st floor Wazy_CSDN response:
first of all determine whether the blob data is empty, and then USES the input stream to read out data
 
The String content=null;
Try {

If (image!=null) {
InputStream is=image. GetBinaryStream ();
Byte [] b=new byte [is available ()];
Is. Read (b, 0, b.l ength);
The content=new String (b);
}
System. The out. Println (content);
} the catch (IOException e) {
e.printStackTrace();
}


Modify the project in this field is String type

CodePudding user response:

Byte array, and then turn the string characters

CodePudding user response:

Do you want to move to the high-level language area for you?

Is a Java or c #
  • Related