Skip to content

Commit 9219e96

Browse files
author
unknown
committed
mbsb - updated refresh the entire database sproc to exclude known deltarunner tables. also better support for tables with spaces.
1 parent 840677c commit 9219e96

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

DataFresh/Resources/PrepareDataFresh.sql

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ AS
163163
DECLARE @CMD NVARCHAR(4000)
164164

165165
DECLARE Table_Cursor CURSOR FOR
166-
SELECT N'bcp ' + DB_NAME() + '.dbo.[' + Table_Name + '] out "' + @BasePath + Table_Name + '.df" -n -k -E -C 1252 -S ' + @@ServerName + ' -T' FROM Information_Schema.tables WHERE table_type = 'BASE TABLE'
166+
SELECT N'bcp "' + DB_NAME() + '.dbo.[' + Table_Name + ']" out "' + @BasePath + Table_Name + '.df" -n -k -E -C 1252 -S ' + @@ServerName + ' -T' FROM Information_Schema.tables WHERE table_type = 'BASE TABLE'
167167

168168
OPEN Table_Cursor
169169
FETCH NEXT FROM Table_Cursor INTO @CMD
@@ -208,7 +208,7 @@ AS
208208

209209
-- Delete All data from Changed Tables and Refill
210210
DECLARE UserTable_Cursor CURSOR FOR
211-
SELECT [tablename] FROM #UserTables WHERE tablename <> 'df_ChangeTracking'
211+
SELECT [tablename] FROM #UserTables WHERE tablename not in ('df_ChangeTracking', 'dr_DeltaVersion')
212212

213213
OPEN UserTable_Cursor
214214

0 commit comments

Comments
 (0)