Wrox Programmer Forums
Go Back   Wrox Programmer Forums > SQL Server > SQL Server 2000 > SQL Server 2000
|
SQL Server 2000 General discussion of Microsoft SQL Server -- for topics that don't fit in one of the more specific SQL Server forums. version 2000 only. There's a new forum for SQL Server 2005.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the SQL Server 2000 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 25th, 2005, 05:40 AM
Friend of Wrox
 
Join Date: Mar 2005
Posts: 264
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
quote:Originally posted by Prashant.k.m


Your data is larger in some string field,

ie, your field width may be 100 and you are trying to insert a string with 101 or greater charecters.

Many many thank to u . well i inserted the following data and it worked wel(http://i5.photobucket.com/albums/y18...od007/form.gif). Could u tell me where i can increase the site of these fields? In the form or in the sql server 2000 ?Thanks


http://i5.photobucket.com/albums/y18...od007/form.gif



 
Old April 25th, 2005, 05:55 AM
Friend of Wrox
 
Join Date: Apr 2005
Posts: 186
Thanks: 0
Thanked 0 Times in 0 Posts
Default


Set the MaxLength Property of the textboxes to the corresponding field width in the DB table. So you will not get any such errors more as the user will not be able to enter more no of charecters.
Now you can enter the data and find out which field is short of width.
If you need more width add that to the DB table field as well as increase the maxlength of the textbox

This should solve the whole problem










 
Old April 27th, 2005, 01:50 PM
Friend of Wrox
 
Join Date: Mar 2005
Posts: 264
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Many thanks for u reply. If i want to user access 2000 db. What part need to be changed ?Thanks

 
Old April 27th, 2005, 11:46 PM
Friend of Wrox
 
Join Date: Apr 2005
Posts: 186
Thanks: 0
Thanked 0 Times in 0 Posts
Default

TO convert to access 2000 db, you should use System.Data.OleDb intsead of System.Data.SqlClient. Thus every thing starting with Sql will start with OleDb (OleDbCommand,OleDbConnection...).
Also enclose date in #.

Regards
Prashant







Similar Threads
Thread Thread Starter Forum Replies Last Post
What is wrong with following Insert Query? [email protected] VB.NET 2002/2003 Basics 1 September 19th, 2006 04:41 PM
Where is wrong of my alert statement? Edward King Javascript How-To 1 May 28th, 2005 05:12 AM
What's wrong with this statement ? levinll SQL Language 4 April 29th, 2004 08:41 PM
What's wrong with this SQL Statement dc925 ADO.NET 4 January 23rd, 2004 11:27 AM
What's wrong with my SQL statement? kaz VS.NET 2002/2003 1 December 11th, 2003 09:21 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.