SQL
Introduces Microsoft SQL Server....
Sunday, March 24, 2013
ORDER BY with REPLACE()
We can you Replace() with ORDER BY in SQL Server 2008 R2. Below is the sample example.
SELECT
ID
,
Name
FROM
(
SELECT
ID
,
Name
FROM
tblPerson
)
AS
OrderTemp
ORDER
BY
REPLACE
(
Name
,
'-'
,
' '
)
Newer Posts
Older Posts
Home
Subscribe to:
Posts (Atom)