Hi, gurus,
I want to get the name of the database for a stored procedure with any t-sql statement if it is achievable? The reason is I am looking at a SQL Server agent job, and one of the job step is to execute a particular stored procedure, but the problem is it does not say where this stored procedure is settled? like which database? I got so many databases here therefore it's going to be a pain and very unaccurate to get the database name of this particular stored procedure.
Therefore I am wondering if there is any way like t-sql statement to retrieve the database name for this particular stored procedure by giving the stored procedure name?
Does any of you here have any answer?
Hope it is clear for your help.
Thanks a lot in advance for your help and I am looking forward to hearing from you shortly.
Best regards,
Yours sincerely,