Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6877911
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T04:39:30+00:00 2026-05-27T04:39:30+00:00

Using VB6 and SQL Server 2000 I want to pass the value to stored

  • 0

Using VB6 and SQL Server 2000

I want to pass the value to stored procedure using rdo connection.

I know stored procedure and rdo connection string, but I don’t know how to pass parameter value to stored procedure through rdo connection.

Tried code

Dim rsql As rdoQuery
                'Set rsql = rdovispay
                rsql.rdoParameters ("Storeprocedure1")
                rsql.rdoParameters(0).Direction = rdParamReturnValue
                rsql(1) = Eid
                rsql.Execute

Can anyone provide a sample code for passing the parameter value to stored procedure?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T04:39:31+00:00Added an answer on May 27, 2026 at 4:39 am

    From MSDN:

    A parameter query simply substitutes user-supplied or application-supplied parameters into an ordinary query. While this query is usually a SELECT statement, it could be an INSERT, UPDATE, or DELETE query as well. The following example illustrates how to code a simple SELECT query with a single parameter. The query looks up authors by name from the Pubs sample database.

    First, set up an SQL query that marks each parameter using the ? parameter marker.

    QSQL$ = "SELECT * FROM Authors WHERE Au_Lname = ?"

    Next, create an rdoQuery object to manage the query and its parameters.

    Set PSAuthors = cn.CreateQuery("",QSQL$)

    Next, use the following code to insert the value entered by the user (Text1.Text) into the query.

    PSAuthors.rdoParameters(0) = Text1.Text

    You can find the complete page here

    You code (ODBC syntax) would be modified to:

    Dim rsql As rdoQuery
    Dim QSQL as string
    
    ' if your data source is ODBC then use the ODBC syntax
    'QSQL$ = "{ ? = call Storeprocedure1 (?) }"
    
    ' if your data source is SQL, then use the SQL syntax
    'QSQL$ = "Execute Storeprocedure1 ?"
    
    Set rsql = Connection.CreateQuery("", QSQL$)
    rsql.rdoParameters(0).Direction = rdParamReturnValue
    rsql(1) = Eid  ' set the input parameter
    rsql.Execute
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Using VB6 and SQL Server 2005 I want to write a sql connection for
Using VB6, SQL Server 2000 I want to connect to others system database. Code:
Using SQL Server 2000 and VB6 Table1 ID Date 001 20090801 001 20090802 …
I am using SQL Server 2000 and feeling stuck about how to do this:
Using SQL Server 2005 and VB6 When I executing for yearly data or more
Using SQL Server and VB6 Table1 Date Time 20090801 060000 20090802 162000 Date Format:
Using VB6 Code. Dim posn As Integer, i As Integer Dim fName As String
Using VB6 I want to compare the system date, if the exe should not
Using VB6 I want to delete the last 5 words of the filename, then
Using SqlServer 2000 and VB6 Table Dates 10/10/2009 (dd/mm/yyyy) 11/10/2009 .... .... Dates Column

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.