We help IT Professionals succeed at work.
Get Started

SQL Get Store Procedure Column Name As Row

167 Views
Last Modified: 2018-03-07
I want to retrieve store procedure columns as row without data.

for example I have store procedure SP_Get_All_Country_List with parameter @Return_Data BIT. If I pass Return_Data=1 then it return value but when I pass Return_Data=0 then no data return.

EXEC SP_Get_All_Country_List @Return_Data=0
it show blank columns as :

Country_ID   Country_Name   Country_Region

Now I want this as :
Country_ID
Country_Name
Country_Region

I don't want data I only want column names as row. simply I want store procedure all columns list.
Comment
Watch Question
Architect
Commented:
This problem has been solved!
Unlock 1 Answer and 5 Comments.
See Answer
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE