Home > Archive > MS SQL Server > December 2006 > How do I find the db name from a stored procedure in the db









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author How do I find the db name from a stored procedure in the db
Kjell Arne Johansen

2006-12-12, 7:12 pm

Hi

I need to know the name of the database from a stored procedure in that
database.
How can I do that?

Regards
Kjell Arne Johansen
Tracy McKibben

2006-12-12, 7:12 pm

Kjell Arne Johansen wrote:
> Hi
>
> I need to know the name of the database from a stored procedure in that
> database.
> How can I do that?
>
> Regards
> Kjell Arne Johansen


DB_NAME()


--
Tracy McKibben
MCDBA
http://www.realsqlguy.com
Kjell Arne Johansen

2006-12-12, 7:12 pm

Hi

Thank You, thats what i needed!

kaj

"Tracy McKibben" wrote:

> Kjell Arne Johansen wrote:
>
> DB_NAME()
>
>
> --
> Tracy McKibben
> MCDBA
> http://www.realsqlguy.com
>

Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com