Results 1 to 3 of 3
  1. #1
    Join Date
    Feb 2004
    Location
    Philadelphia,PA
    Posts
    4

    Unanswered: replacing "{ call [Stored proc] ??}" syntax

    Hey All,

    We are using RDO to get results from Sybase stored procedures in VB6. In
    most cases the stored proc results are put into a resultset, so we can call
    the stored proc using the "EXEC [stored proc name]" syntax preferred by our
    DBAs. However, in the case of stored procs that take input/ output
    parameters, this doesn't work. We are forced to use the { call [stored proc
    name] ? ? ?}" syntax. Is there any way in RDO, ADO, or ADO.NEt to get those results without using the syntax that the DBAs hate?

    I'd love to say that it's got to be ADO.Net. I am so beyond sick of RDO

    Thanks

  2. #2
    Join Date
    Feb 2002
    Posts
    13
    Dim rs As Recordset

    fsql = "exec proc_name'" & par1 & "','" & par2 & "'," & par3 & "," & par4 & ""

    Set rs = db.OpenRecordset(fsql, dbOpenSnapshot, dbSQLPassThrough)




    the said above works in VB5 without any problem . The other syntax also works :
    { call [stored proc name] ? ? ?}"

    I do not think RDO is need to be blamed.

  3. #3
    Join Date
    Feb 2004
    Location
    Philadelphia,PA
    Posts
    4

    Thanks

    Thanks for the repy. The problem was a misunderstanding of what they wanted. I have to use the Exec [stored proc name] ??? (wuestion mark for every parameter) if there are output parameters. Otherwize I can just call the stored proc using the exec [storeproc name] value1,2,etc.

    I thought that the DBA was telling me he didn't want paramaterized queries, but what he was saying is that the {call} syntax has a lot of overhead.

    Thanks again.

Posting Permissions

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