aspose file tools*
The moose likes JDBC and the fly likes text field in stored procedure Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "text field in stored procedure" Watch "text field in stored procedure" New topic
Author

text field in stored procedure

joseph cooper
Ranch Hand

Joined: Nov 08, 2005
Posts: 44
There is a text field defined in the database. I am working with a stored procedures and trying to insert information into this text field. I am receiving this error: "The text, ntext, and image data types are invalid for local variables."

-- code --

declare @Bas_Txt as text
declare @Bas_Cmt_Tx as varchar(200)
set @Bas_Txt = '<HTML> </HTML>'
set @Bas_Cmt_Tx = 'trial setup'

BEGIN
Set NoCount On
Insert into dbo.BASELINE(Bas_Txt, Bas_Cmt_Tx)
Values (@Bas_Txt, @Bas_Cmt_Tx)
END

I have done some looking on google and I am not sure if this can be done. If not, is there a work around?

thanks in advance.
stu derby
Ranch Hand

Joined: Dec 15, 2005
Posts: 333
Stored procedure languages are (usually) specific to their databases, and have nothing to do with Java; you'll probably have better luck on a forum dedicated to whatever database you are using (I can't tell, I don't recognize that particular stored procedure language).
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 29253
    
139

Joseph,
It is ok to ask stored procedure questions here at JavaRanch. I recommend editing your post to put the language/database you are using in the subject. That way people who know that language/database are sure to read your post.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
joseph cooper
Ranch Hand

Joined: Nov 08, 2005
Posts: 44
I am working with SQL2000 and windows XP.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: text field in stored procedure
 
Similar Threads
Simple dynamic expression evaluation not working
setting the entered value in a text field to a variable
setting the value to a form of html
Struts Validator Configuration
actionListener for JLabel