Image as Output from Stored Procedure

  • Hi

    How to pass image/text data as output parameter from a stored procedure. The sql server BOL explains in the create procedure section that output parameter can be image/text also.

    Thx

  • doesnt this work

    CREATE PROCEDURE <Proc Name> @Var text OUTPUT

    AS

  • create table test ( c1 int, c2 text)

    go

    create proc test_text ( @var text output )

    as

    select @var= c2 from test

    go

    exec test_text

    This throws error, assignment is wrong.

  • oh yes , you can't assign to a text variable ... makes it virtually useless i guess ... you can write "select c2 from test" instead which would return the text field as output!!!

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply