August 25, 2008 at 11:03 pm
In our database we have more than 2500 StoredProcedures. Name of the SP is having some conventions like versions appending to it.
(e.g) pcarlist_260000
pbuslist_221000
p_vehiclelist_280000. n etc(Without versions too)
Now i want to see all the versions available in my database....
(i.e) How to separate the versions from each name?
August 26, 2008 at 1:15 am
To select all SP's with a specific versionnumber:
select * from sys.objects where type = 'P' AND name LIKE '%_268000'
To see all used versions (including how many SP's are available in that version):
select
count (object_ID) as NumberOfSP
, right(name, 7) as VersionNumber
from sys.objects
where type = 'P'
group by right(name, 7)
Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy