Using Results of SP

Using Results of SP

Post by Mike Meerdin » Wed, 22 Sep 1999 04:00:00



I am new to SQLServer and require some guidance.
I want to create a stored procedure that creates triggers.
To do this I need to figure out the fields on a given database that make up
the primary key.
The sp_pkey stored procedure returns what I want but I don't know how to
extract the fields names and concatenate them into a comma delimited string.
I could cut and paste the code out of sp_key and use it in my own sp but
that defeats the purpose of what I am trying to do.
Are there any good references that could benefit the novice trying to get up
to speed on SQL 7.0 ?