Like shown below i have 3 columns(Name,No,Address). The
values in name column i want to modity.
Requirement : Keep only once space between two words
(Fname,Lname) in the Name column.
For this what is the query? Please answer me. Advance
Thanks.
Name No Address Reference
manoj kumar
kumar raja
vinzay kumar
rajendra prasad
gowri nath -- -- --
Answer Posted / lince
select substring(NAME,1,charindex(' ',NAME))+' '+
replace(substring(NAME,charindex(' ',NAME),len(NAME)),' ','')
as NAME from test
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
How do I make my sql query run faster?
which operator is used in query for pattern matching? : Sql dba
What is the maximum size of sqlite database?
What is the difference between count 1 and count (*) in a sql query?
What is the max nvarchar size?
What is sql stand for?
how to create a new table by selecting rows from another table in mysql? : Sql dba
Why we use sql profiler?
Does execute immediate commit?
What is the non-clustered index in sql?
how to check server status with 'mysqladmin'? : Sql dba
What is fmtonly in sql?
What is difference between hql and sql?
What are variables in pl sql?
Differentiate between pl/sql and sql?