borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder

AndreaVB | Forum | News | Downloads | Register | Help | Member List | Statistics | Search | PM | Profile

Print This Topic
Previous Topic (stored procedures)Next Topic (Data Objects that are used as an interface to Databases) New Topic New Poll Post Reply
AndreaVB Forum : Database : Stored procedures with parameters using OLE DB
Poster Message
larosal
Level: Guest


icon Stored procedures with parameters using OLE DB  Archived to Disk

Can anybody tell me by an example how I can execute SQLServer stored procedures with parameters in VB using OLE DB?

Thanks a lot

02-05-2002 at 10:22 PM
| Quote Reply
JLRodgers
Level: Moderator

Registered: 04-04-2002
Posts: 1617
icon Re: Stored procedures with parameters using OLE DB  Archived to Disk

Similar to the below, although it will depend on what data types it's looking for (text or numbers) as to how you'll pass it.


ADODBConnection.Execute "[StoredProcedureName] 'Text'"

ADODBConnection.Execute "[StoredProcedureName] 24"

ADODBConnection.Execute "[StoredProcedureName] 'Text', 24"



____________________________
Everywhere's Local (classifieds, job postings, & more for everycity in the world - user entered)

02-05-2002 at 10:33 PM
View Profile Send Email to User Show All Posts Visit Homepage | Quote Reply
larosal
Level: Guest

icon Re: Re: Stored procedures with parameters using OLE DB  Archived to Disk

So, there's no difference between executing stored procedures by ADO and OLE DB?

Thanks again

09-05-2002 at 04:09 AM
| Quote Reply
JLRodgers
Level: Moderator

Registered: 04-04-2002
Posts: 1617
icon Re: Stored procedures with parameters using OLE DB  Archived to Disk

Well, according to the control list in VB, the ADODC control (ado) is listed as "Microsoft ADO Data Control 6.0 (SP4)(OLEDB)" which adds the reference to the "Microsoft ActiveX Data Objects". So it would seem that OLEDB and ADO are the same in microsoft's eyes.

Or another simpler way from the help file (modified): OLE DB Support

OLE DB is a set of COM interfaces ... support the amount of DBMS functionality ... ADO is the way that programmers access OLE DB....

09-05-2002 at 05:48 AM
View Profile Send Email to User Show All Posts Visit Homepage | Quote Reply
AndreaVB Forum : Database : Stored procedures with parameters using OLE DB
Previous Topic (stored procedures)Next Topic (Data Objects that are used as an interface to Databases) New Topic New Poll Post Reply
Surf To:


Not Logged In? Username: Password: Lost your password?
Partners: Download Actual Software | Free Software Download
borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder