Skip to Main Content

How to covert column names into rows in SQL?

User_CK8A6May 19 2021 — edited May 19 2021

I have following requirement from my user.
I have a table which has column col1, col2, col3 and col4. Now using SQL I want the output to be displayed as
Col1 Col2
col1 col3
col1 col4
Please suggest how can we achieve this?
Thanks

Comments
Post Details
Added on May 19 2021
9 comments
80 views