I suggest you ...

How to reference the parameter from from iSQl to SQL Store Procedure ?

I want to pass value back from my store procedure to a variable in xcode.

Any idea to help me?

1 vote
Vote 0 votes Vote Vote
Vote
Sign in
Check!
(thinking…)
Reset
or sign in with
  • facebook
  • google
    Password icon
    I agree to the terms of service

    You'll receive a confirmation email with a link to create a password (optional).

    Signed in as (Sign out)
    You have left! (?) (thinking…)
    VanhakVanhak shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

    1 comment

    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      I agree to the terms of service

      You'll receive a confirmation email with a link to create a password (optional).

      Signed in as (Sign out)
      Submitting...
      • mobile[foo]Adminmobile[foo] (MobileFoo, MobileFoo) commented  ·   ·  Flag as inappropriate

        Assuming your stored procedure already has an appropriate output parameter, you can then just SELECT that after executing it, for example:

        DECLARE @someParam varchar(100)
        EXEC myProcedure, @myProcOutputParam=@someParam OUTPUT
        SELECT @someParam

        You can then retrieve the result of the select statement as normal. (Though it may not be the first resultSet, if I remember correctly - you might have to skip over an empty one first.

        Thanks,
        Rob
        mobile[foo]

      Knowledge Base and Helpdesk