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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Calling a stored proc using OLE help please

Status
Not open for further replies.

aco636

IS-IT--Management
Nov 25, 2003
212
0
0
GB
Hi All
As always any help gratefully received.

I would like some advice calling a stored proc from a vbScript

I have tried several methods
Code:
cnIfmx.BeginTrans
Set cmd.ActiveConnection = cnIfmx
cmd.CommandType() = 4
cmd.CommandText = "CALL sp_myProc (?,?,?,?,?,?,?,?,?,?)"
cmd.Execute

and also
Code:
cnIfmx.BeginTrans
Set cmd.ActiveConnection = cnIfmx
cmd.CommandType() = 4
cmd.CommandText = CALL sp_myProc (" & iSerialNo & ",0,'[URL unfurl="true"]WWW',NULL,NULL,30,NULL,'"[/URL] & strComment & "'," & iEngNo & ",'" & strEngName & "' );"
cmd.Execute

also have tried with without Call statement. No errors returned from the connection object?

Its worth noting that myProc does return 2 values that I dont bother to read since they are not required for the project I am writing.

Any help very appreciated.
Regards ACO
 
What about this ?
cmd.CommandType = 1 ' 1=adCmdText

Hope This Helps, PH.
FAQ219-2884
FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top