Hi, I obtain this error when i do a INSERT SQL command in a table where CLOB field is present.
Example
create table ART_1 (
id number(5,0) not null,
testo CLOB not null
)
.........
valore:='TEST'
sql.Text:='insert into ART_1 values (100,:a1)';
Params[0].DataType:=ftOraClob;
stream:=TStringStream.create(valore);
stream.Position:=0;
Params[0].LoadFromStream(stream,ftOraClob);
stream.free;
ExecSQL();
Thanks.
ORA-22275: invalid LOB locator specified
Re: ORA-22275: invalid LOB locator specified
Hello,
To insert CLOB/BLOB values, you should use Oracle EMPTY_CLOB/EMPTY_BLOB functions. The following is your fixed sample:
To insert CLOB/BLOB values, you should use Oracle EMPTY_CLOB/EMPTY_BLOB functions. The following is your fixed sample:
Code: Select all
valore := 'TEST';
SQLQuery1.sql.Text := 'insert into ART_1(id, testo) values (100,EMPTY_CLOB()) RETURNING testo INTO :testo';
SQLQuery1.Params[0].ParamType := ptInput;
SQLQuery1.Params[0].DataType := ftOraClob;
stream := TStringStream.create(valore);
stream.Position:=0;
SQLQuery1.Params[0].LoadFromStream(stream,ftOraClob);
stream.free;
SQLQuery1.ExecSQL();
Re: ORA-22275: invalid LOB locator specified
thanks for reply.
it's work.
thank you very much!
it's work.
thank you very much!
Re: ORA-22275: invalid LOB locator specified
Hello,
Glad to see that the problem was solved. If you have any other questions, feel free to contact us.
Glad to see that the problem was solved. If you have any other questions, feel free to contact us.
Re: ORA-22275: invalid LOB locator specified
sorry. I have the same problem.
I have to use stored procedure to assigned the clob field.
How could I specify the LOB locator through stored procedure?
I have to use stored procedure to assigned the clob field.
How could I specify the LOB locator through stored procedure?
Re: ORA-22275: invalid LOB locator specified
Hello,
Please specify your IDE version
Please specify your IDE version