Results 1 to 4 of 4

Thread: vb side when writing s proc

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Mar 2005
    Posts
    334

    vb side when writing s proc

    I have wrote a s proc and want to call it in ma code.... all fines just getting a bit confused

    Set prmName = objCmd.CreateParameter("Name", adVarChar, adParamInput, 15)
    objCmd.Parameters.Append prmName

    "Name" - should this be the name of the parameter in the s proc OR the column name in the table!!1!!!!

  2. #2
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    Re: vb side when writing s proc

    With ADO the name can be whatever you want.

    My advice, set the name argument equal to the parameter name.

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Mar 2005
    Posts
    334

    Re: vb side when writing s proc

    thanks 1 over question, I need to set ALL the parameters in the vb code that in the s procedure, correct? or can i ignore the parameters that do not apply; ie i want them sed to default values????

  4. #4
    PowerPoster techgnome's Avatar
    Join Date
    May 2002
    Posts
    34,687

    Re: vb side when writing s proc

    If 1) defaults have been specified on the parameter, and 2) if you are not specifying any more parameters.

    Example, if the SP takes 3 parameters, and you want to specify 1 & 3... you also have to specify 2.

    Tg
    * I don't respond to private (PM) requests for help. It's not conducive to the general learning of others.*
    * I also don't respond to friend requests. Save a few bits and don't bother. I'll just end up rejecting anyways.*
    * How to get EFFECTIVE help: The Hitchhiker's Guide to Getting Help at VBF - Removing eels from your hovercraft *
    * How to Use Parameters * Create Disconnected ADO Recordset Clones * Set your VB6 ActiveX Compatibility * Get rid of those pesky VB Line Numbers * I swear I saved my data, where'd it run off to??? *

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width