SQLTeam.com | Weblogs | Forums

Grid results alignment


#1

I have a problem When i insert data into a field of same length, when i select the results in grid view they are not align correctly but when i select results to text they are a well aligned.

what could be causing this and how can i get them corrrectly aligned?

the kind of data am inserting are like 'Personal Account 20,000.00' They are are all of lenght of 55.
see sample below

SQL 2005 & 2008


#2

looks like there are trailing spaces.can you use the TRIM function and check.


#3

i am using spaces in between the text to fill the required length


#4

First let me say you should not use SQL to format data. :slight_smile:

Check your font. If it is proportional then your spaces will not match.

You did not include your code so I do not know where to help you.