| Author |
Topic  |
|
|
jfm
Posting Yak Master
134 Posts |
Posted - 09/13/2012 : 12:53:25
|
Hi there,
I have an ID_Column. The matter is that the data is as follows:
AXBN- JT3
AXBN-JT3
I have some middle spaces in some cells. I need to remove those spaces, because SQL is recognizing the cells as a different one, due to that middle space.
Anyone knows any query to remove it?
Many thanks |
|
|
tkizer
Almighty SQL Goddess
USA
35007 Posts |
|
|
jfm
Posting Yak Master
134 Posts |
Posted - 09/13/2012 : 13:02:40
|
How you will write the query?
Using Monthly_Table and Mydatabase.
Regards |
 |
|
|
jfm
Posting Yak Master
134 Posts |
Posted - 09/13/2012 : 13:06:18
|
I used the following query to remove the left and right spaces. But i cant remove the middle ones:
UPDATE table SET ax = replace ( ax, ax, RTRIM(ltrim( ax))) where ax <>''
Thanks |
 |
|
|
tkizer
Almighty SQL Goddess
USA
35007 Posts |
|
|
jfm
Posting Yak Master
134 Posts |
Posted - 09/13/2012 : 13:32:16
|
Perfect.
I used them, because, I'd take info from other columns and they had spaces too.
Thanks! |
 |
|
|
tkizer
Almighty SQL Goddess
USA
35007 Posts |
|
| |
Topic  |
|