Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 06c764f

Browse files
committed
Renames output log files
1 parent 805a1a0 commit 06c764f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

‎Powershell/CopyDatabase.ps1‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,12 @@ foreach($sql in $DS.Tables[0].Rows){
2727
Invoke-Expression $bcp
2828
Write-Output $bcp
2929

30-
$bcp = "bcp $($sql.SchemaName).$($sql.TableName) out $($tempPath)$($sql.TableName).bcp -S $($ServerName) -d $($SourceDatabase) -U $($UserName) -P $($Password) -E -n -t -e $($logPath)$($sql.TableName)_in_err.txt"
30+
$bcp = "bcp $($sql.SchemaName).$($sql.TableName) out $($tempPath)$($sql.TableName).bcp -S $($ServerName) -d $($SourceDatabase) -U $($UserName) -P $($Password) -E -n -t -e $($logPath)$($sql.TableName)_out_err.txt"
3131
Invoke-Expression $bcp
3232
Write-Output $bcp
3333

3434
#add code to import in to use format file
35-
$bcp = "bcp $($sql.SchemaName).$($sql.TableName) in $($tempPath)$($sql.TableName).bcp -S $($DestinationServer) -d $($DestinationDB) -T -t -E -f $($tempPath)$($sql.TableName).fmt -e $($logPath)$($sql.TableName)_out_err.txt"
35+
$bcp = "bcp $($sql.SchemaName).$($sql.TableName) in $($tempPath)$($sql.TableName).bcp -S $($DestinationServer) -d $($DestinationDB) -T -t -E -f $($tempPath)$($sql.TableName).fmt -e $($logPath)$($sql.TableName)_in_err.txt"
3636
Invoke-Expression $bcp
3737
Write-Output $bcp
3838

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /