I am sorry that I am poor at English.
On the server side, attempt to insert it into the Blob column.
Mysql normally contains data.
but in Oracle 0byte Data Inserted.
using this code ,
queryString := ‘INESRT INTO TABLE(COL_BLOB) VALUES(:COL_BLOB)’;
DaSQL := ClientConnection.NewCommand(queryString, stSQL, ‘’);
DaSQL.Params[0].LoadFromFile(‘C:\1.jpg’);
DaSQL.Params[0].DataType := datBlob;
DaSQL.Params[0].BlobType := dabtOraBlob; // and try dabtBlob , but doesn’t work.
DaSQL.Params[0].ParamType := daptInput;
DaSQL.Execute;
How do I fix it? Thanks Regards.
EvgenyK
(Evgeny Karpov)
June 22, 2017, 8:18am
2
pls specify your version of Delphi and what driver (FireDAC, ODAC, etc) was used.
Thanks for your prompt reply…
Delphi Version is XE10 Seattle,
and Drive used ODAC
EvgenyK
(Evgeny Karpov)
June 22, 2017, 2:50pm
4
have you tested MYDAC and ODAC drivers?
what version of DA you are using?
DA ver 9.0.97
and i haven’t mydac, using Zeos Library connect MYSQL,
Oracle Access uses ODAC…
ZEOS Drive use then BLOB type insert to not problem,
but if ODAC use then BLOB type insert, but empty data inserted
EvgenyK
(Evgeny Karpov)
June 23, 2017, 9:07am
6
DA 9.0.97 was released an year ago.
Can you reproduce this problem with ODAC driver with latest RTM or Beta?
Note: you can use DA trial if you haven’t access to the latest full version
EvgenyK
(Evgeny Karpov)
June 27, 2017, 3:10pm
7
try to load data after datatype is set, i.e.
queryString := 'INESRT INTO TABLE(COL_BLOB) VALUES(:COL_BLOB)';
DaSQL := ClientConnection.NewCommand(queryString, stSQL, '');
DaSQL.Params[0].DataType := datBlob;
DaSQL.Params[0].BlobType := dabtOraBlob; // and try dabtBlob , but doesn't work.
DaSQL.Params[0].ParamType := daptInput;
DaSQL.Params[0].LoadFromFile('C:\1.jpg'); //<<<<<<<<<<<<<<<moved
DaSQL.Execute;