Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Arguments are of the wrong type...

Status
Not open for further replies.

acabrera

Programmer
Jan 22, 2004
44
US
I have a Delphi 7 project using an Oracle 9i database and ADO connection/query.

In the application, I get the error message: Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another. A similar application using the ODAC did not cause any problem.

The error comes from the statement which defines the value of the parameter.

var paysr:integer; usrnm:string;

ADOLogin;
paysr:=StrToInt(usrnm);
with ADOqryUser do
begin
close;
Parameters.ParamByName('PAYSR_ID').Value:=paysr;
Open;
end;

The parameter PAYSR_ID is of type ftInteger and direction pdInput.


ADOLogin is a procedure which sets the ADO connection string and opens the connection.

with ADOConnection do
begin
ConnectionString:='Provider=OraOLEDB.Oracle.1;' +
'Password=' + password + ';Persist Security ' +
'Info=True;User ID=' + username + ';Data Source=ORAD';
Open;
end;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top