p2p.wrox.com Forums

p2p.wrox.com Forums (http://p2p.wrox.com/index.php)
-   SQL Language (http://p2p.wrox.com/forumdisplay.php?f=100)
-   -   long text field (http://p2p.wrox.com/showthread.php?t=68632)

SKhna June 6th, 2008 04:44 AM

long text field
 
 Hi

I have a textbox field that take 2000 characters from user..Then I used a store procedure to save that user input into database through an insert statement, but for some reason it just never store the whole string of 2000 characters but only store some of it (like 100 or something) .. Seems like a data type problem…(I am using SQL server 2000)



This is what I have defined:



---------------------------------------

In storeprocedure:



@iidea2 varchar(2000)





Table Design



Idea2 varchar 2000





Aspx page



cmd.Parameters.Add(New SqlParameter("@iidea2", SqlDbType.VarChar)).Value = Idea2




Imar June 6th, 2008 12:43 PM

Hi there,

Have you tried creating a SqlParameter explicitly and setting its Size property?

http://msdn.microsoft.com/en-us/libr...parameter.aspx

Imar


---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of Beginning ASP.NET 3.5 : in C# and VB, ASP.NET 2.0 Instant Results and Dreamweaver MX 2004
Want to be my colleague? Then check out this post.


All times are GMT -4. The time now is 02:41 PM.

Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.