File tree Expand file tree Collapse file tree 2 files changed +26
-0
lines changed
Expand file tree Collapse file tree 2 files changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -58,6 +58,8 @@ sqlcmd -S %_server% -d %_database% -U %_username% -P %_password% -I -i .\functio
5858ECHO Deploying views
5959
6060REM Views
61+ sqlcmd -S %_server% -d %_database% -U %_username% -P %_password% -I -i .\views\dbc.databases.sql
62+ sqlcmd -S %_server% -d %_database% -U %_username% -P %_password% -I -i .\views\dbc.tables.sql
6163sqlcmd -S %_server% -d %_database% -U %_username% -P %_password% -I -i .\views\microsoft.dw_active_queries.sql
6264sqlcmd -S %_server% -d %_database% -U %_username% -P %_password% -I -i .\views\microsoft.dw_active_queue.sql
6365sqlcmd -S %_server% -d %_database% -U %_username% -P %_password% -I -i .\views\microsoft.dw_configuration.sql
Original file line number Diff line number Diff line change 1+ DROP VIEW IF EXISTS [dbc].[databases];
2+ GO
3+
4+ CREATE VIEW [dbc].[databases] AS
5+ SELECT
6+ [DatabaseName] = d .name
7+ , [CreatorName] = ' dbo'
8+ , [OwnerName] = ' dbo'
9+ , [AccountName] = ' dbo'
10+ , [ProtectionType] = ' N'
11+ , [JournalFlag] = ' NN'
12+ , [PermSpace] = 0
13+ , [SpoolSpace] = 0
14+ , [TempSpace] = 0
15+ , [CommentString] = NULL
16+ , [CreateTimeStamp] = d .create_date
17+ , [LastAlterName] = ' dbo'
18+ , [LastAlterTimeStamp] = d .create_date
19+ , [DBKind] = ' U' -- or 'D'
20+ , [AccessCount] = NULL
21+ , [LastAccessTimeStamp] = NULL
22+ FROM
23+ sys .databases d
24+ GO
You can’t perform that action at this time.
0 commit comments