zl程序教程

您现在的位置是:首页 >  后端

当前栏目

java.sql.SQLException:内部错误:UnabletoconstructaDatumfromthespecifiedinput

JAVA错误SQL 内部 SQLException
2023-06-13 09:14:02 时间
Q:
IamworkingwithOracledatabase8.1.7andIhavewrittenaJAVAcodetoupdatethetablewhichcontainsoneBLOBfield.

IamusingupdateBinaryStreammethodofresultsettoupdatetheBLOBfieldbutitisfailingaftergivingfollowingexception

java.sql.SQLException:InternalError:UnabletoconstructaDatumfromthespecifiedinput

Cananyonehelpmeinthisregard?


A:
That"sbecauseyouareusingFileInputStream.FileInputStreamdoesn"timplementallmethodsofjava.io.InputStream.Usejava.io.Fileinstead.