Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 

Get your favorite SSC scripts directly in SSMS with the free SQL Scripts addin. Search for scripts directly from SSMS, and instantly access any saved scripts in your SSC briefcase from the favorites tab.
Download now (direct download link)

Get name of current database

By AJ Ahrens,

Retrieve the name of the current database for use with bcp and other procedures that require database name. 

This will help increase the portability of code and less maintenance required when migrating code to new database/server.

Total article views: 157 | Views in the last 30 days: 1
 
Related Articles
FORUM

Database

Database

FORUM

Database Sync

Database

FORUM

Database suspect

Database

FORUM
FORUM

Database Synchronization

Database Synchronization

Tags
miscellaneous    
t-sql    
 
Contribute