Skip to content

Commit f529114

Browse files
notes update for unregistering
1 parent abc37f7 commit f529114

File tree

4 files changed

+540
-7
lines changed

4 files changed

+540
-7
lines changed

Invoke-RandomWorkload.ps1

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ https://www.sqlskills.com/blogs/jonathan/the-adventureworks2008r2-books-online-r
6060

6161
function Invoke-RandomWorkload {
6262
#Requires -Module PoshRsJob
63-
#Requires -Module SQLServer
63+
#Requires -Module dbatools
6464
Param(
6565
[string]$SqlInstance,
6666
[pscredential]$SqlCredential,
@@ -89,7 +89,8 @@ Param(
8989
# Pick a Random Query from the input object
9090
$Query = Get-Random -InputObject $Queries
9191
# Run the Query
92-
Invoke-SqlCmd -ServerInstance $Using:SqlInstance -Credential $Using:SqlCredential -Database $Using:Database -Query $Query
92+
# Write-Output "Invoke-DbaQuery -SqlInstance $Using:SqlInstance -SqlCredential $Using:SqlCredential -Database $Using:Database -Query $Query"
93+
Invoke-DbaQuery -SqlInstance $Using:SqlInstance -SqlCredential $Using:SqlCredential -Database $Using:Database -Query $Query
9394
# Choose a random number of milliseconds to wait
9495
$a = Get-Random -Maximum 2000 -Minimum 100;
9596
Start-Sleep -Milliseconds $a;

0 commit comments

Comments
 (0)