New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix issue 17 #18

merged 1 commit into from Jan 8, 2018
Jump to file or symbol
Failed to load files and symbols.
+1 −1
Diff settings


Just for now

@@ -74,7 +74,7 @@ Disconnect-SqlConnection -SqlDisconnect $SqlConnection
$ds = $db.ExecuteWithResults("select owner_sid from sysschedules syssch where = '$ServerSchedule'")
[string]$JobScheduleOwnerSid = $ds.Tables[0].Rows[0]."owner_sid"
if ($CurrentUserSid -notmatch $JobScheduleOwnerSid)
if(@(Compare-Object $CurrentUserSid $JobScheduleOwnerSid -SyncWindow 0).Length -gt 0)
Write-Error "User $whoAmI is not owner of Schedule $ServerSchedule. Either alter or set user executing PowerShell to sysadmin!"
ProTip! Use n and p to navigate between commits in a pull request.