4> USE Northwind; 5> DECLARE @db AS NVARCHAR(258); 6> SET @db = QUOTENAME(N'pubs'); 7> EXEC(N'USE ' + @db + N'; EXEC(''SELECT DB_NAME();'');'); 8> GO