Returning a text field via store proc, error 409

Results 1 to 2 of 2

Thread: Returning a text field via store proc, error 409

  1. #1
    Join Date
    Dec 1969

    Default Returning a text field via store proc, error 409

    I am having a problem with a stored proc in SQL 2000 Ent edition. I make my proc as usual, in this case (simplified for this post) I am just returning some data.<BR><BR>It works fine until I add the "notes_ch" field data as that field in the DB is a "text" field. See the SP below, when I try to add that via the Ent Manager I get this Error 409 back saying I can&#039;t use a text field.<BR><BR>I checked the online help and actually found it to say you CAN use text, ntext, etc, etc.<BR><BR>This one is really confusing me. I am just trying to return some plain text from a text field but must be missing something. I even tried adding it as "text(16)" in the SP but of course that didn&#039;t work.<BR><BR>Thanks for any help....SP below...<BR>-Matt<BR><BR><BR>CREATE PROCEDURE AdminProductsEdit<BR> @id_product int,<BR> @storetype int OUTPUT,<BR> @notes_ch text OUTPUT<BR>AS<BR><BR>SELECT<BR> @storetype = storetype,<BR> @notes_ch = notes_ch<BR>FROM<BR> products<BR>WHERE<BR> id_product = @id_product<BR>GO<BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: Returning a text field via store proc, error 4

    I have always had the same problem with text, ntext and binary fields as sproc outputs and have wondered why the docs say _very_ specificly that these types are supported. If anyone can shed any light on this it would be great to hear. I just use recordsets instead:<BR><BR>CREATE PROCEDURE AdminProductsEdit<BR>@id_product int<BR>AS<BR>SELECT<BR>storetype,<BR>notes_ch<BR>F ROM<BR>products<BR>WHERE<BR>id_product = @id_product<BR><BR>regards,<BR><BR>Dave Kawliche<BR><BR>

Posting Permissions

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