Home > Interview Questions > SQL Server > What is the use of REVERSE() function in SQL server?

What is the use of REVERSE() function in SQL server?

by Narain Siddharth   on 01/06/2011   Category: SQL Server   |  Level: Beginner   |  Views: 1478    |  Points: 25     |  Silver 


The REVERSE() function in SQL server is used to returns the reverse of given string/column. for example if you want to reverse the employee firstname colum, see the below sample

SELECT REVERSE(emp_firstname) 
FROM employee
ORDER BY emp_firstname
//results like as shown below

emp_firstname
--------------------
aasewaI
sadwaR
cdseeP
ccfeJ
xcvdsfeeasG
ccxndfweksD
sdfcxcvdM




« what is the use of LOWER() and UPPER() function in SQL server?
» what is the use of @@TRANCOUNT function in SQL server?
Post Question  |  Question Home

Recent Posts

User Responses


No response found, be the first to review this question.

Submit feedback about this code snippet

Please sign in to post feedback

Latest Posts