Board index » delphi » ADO, stored proc and MSSQL question.
Dodgy
![]() Delphi Developer |
Mon, 31 Oct 2005 20:57:52 GMT
ADO, stored proc and MSSQL question.
Hi,
I'm completely new to accessing stored procedures from Delphi, and I'm My procedure has 1 in, and 4 outs, not including the return value. All the parameters are of type varchar, and the result code is The stored proc appears to execute, but I can't work out how to read The example code for createparameter says to use nil if you don't have adostoredproc1.ProcedureName:='cccheck'; adostoredproc1.Parameters.CreateParameter('@card',ftstring,pdinput,24,edit1 adostoredproc1.parameters.CreateParameter('@issue',ftstring,pdoutput,2,null adostoredproc1.parameters.CreateParameter('@start',ftstring,pdoutput,2,null adostoredproc1.parameters.CreateParameter('@accept',ftstring,pdoutput,2,nul adostoredproc1.parameters.CreateParameter('@oklen',ftstring,pdoutput,2,null // the following line works, and shows my input param memo1.lines.add(adostoredproc1.parameters.parambyname('@card').value); // but this gives me an invalid variant type conversion. memo1.lines.add(adostoredproc1.parameters.parambyname('@issue').value); Can anyone help me out on this, oh, and how do I read the result code? TIA. Dodgy. |