CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 cutting of extra spaces from fields in MS SQL

Print topic Send  topic

Author Message
b@s
Posted: 05/01/2002, 10:57 AM

I am using ASP with a MS SQL database. When I want to modify any fields from any table they show up with all the length that the field has been defined for.
Say for the table Users in the Field Name which is text and with a length of 30, and say the name written is David which is only 5 characters long, in the Record Form it will have David written and after it will put "spaces" to fill in the 30 characters in length.

Is there a way to solve this problem, and even if the field is set for a maximum of 30 to just show what is stored in it like David.

Thanks
Mehmet Ozdemir
Posted: 05/01/2002, 3:47 PM

your are using char or nchar, this will pad the unused characters, instead use varchar or nvarchar. prefix if n being the international support.
b@a
Posted: 05/01/2002, 10:22 PM

Thanks
by using varchar the problem has been solved!

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

MS Access to Web

Convert MS Access to Web.
Join thousands of Web developers who build Web applications with minimal coding.

CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.