Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Development Tools
 ASP.NET
 declaring varchar(max) in c# class

Author  Topic 

afrika
Master Smack Fu Yak Hacker

2706 Posts

Posted - 2008-05-02 : 04:39:18
Hello,

am using c# and a Stored proceedure in MS SQL 2005.

For data size i used the varchar (max) in my stored proceedure. But in the c# class. What do i use ? Here is a line of my code

thanks

Ehi



 command.Parameters.Add(new SqlParameter("@csv", SqlDbType.VarChar, 8000, "recipients"));



afrika
Master Smack Fu Yak Hacker

2706 Posts

Posted - 2008-05-03 : 16:25:12
Ok I got it to work. I just removed the data size

command.Parameters.Add(new SqlParameter("@csv", SqlDbType.VarChar));
Go to Top of Page
   

- Advertisement -