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

VB, DB2, ODBC, Stored Procedure

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
What's the best way to call a stored procedure(with parameters) in VB using an ODBC DB2 interface?

 
When ever I call a stored procedure I just:

------------------------------------

set [Recordset] = [Connection].Execute("EXEC [Stored Procedure Name] [Parameter1], [Parameter2], [etc.]")

------------------------------------

But, there are several other ways also.
(Use the Command Object, Recordset.Open, etc.)

It really just comes down to what you are really doing and what you need.

(Note: My experience is with SQL Server, but the SQL should be similar.)

- Bill

 
Thanks Bill. I guess my question is geared more towards the DB2 syntax side of things? I have accessed stored procedures against a SQL Server in the past just as you have suggested. Thanks though!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top