This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Atomic exec of a script | |
BEGIN TRY | |
BEGIN TRANSACTION | |
... | |
COMMIT TRANSACTION | |
END TRY | |
BEGIN CATCH | |
ROLLBACK TRANSACTION; | |
THROW |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Kill connections on a db | |
CREATE PROCEDURE dbo.clearDBUsers | |
@dbName SYSNAME | |
AS | |
BEGIN | |
SET NOCOUNT ON | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Show list of PID - WPs | |
C:\Windows\System32\inetsrv>appcmd list wp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$token = "" | |
$org = "acme" | |
$gitRepoUri = "https://api.github.com/orgs/$org/repos?access_token=$token" | |
$workdir = "C:/backup/git" | |
$git = "C:\Program Files\Git\cmd\git.exe" | |
$branches = "master","develop" # branches to zip | |
#$filter = "Team"; # leave empty if all repo | |
#restore : | |
# 1) go to the folder (.git) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://marketplace.visualstudio.com/items?itemName=MikeWard-AnnArbor.VSColorOutput |
- use: implicits, types depends on each others, scala 2.x does not allow multiple implicits "brackets" for a trait
- ref: https://gigiigig.github.io/posts/2015/09/13/aux-pattern.html
// the trait
def foo[A, B, R](implicit foo: Foo.Aux[A, B], monoid: Monoid[R], ev: B =:= R): R = ???
// boilerplate for the Aux
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DataRecord:=GetDataRecord(ElementNo); | |
with DataRecord do begin | |
if Grade>=3 then begin | |
if Repetition=0 then begin | |
Interval:=1; | |
Repetition:=1; | |
end else if Repetition=1 then begin | |
Interval:=6; | |
Repetition:=2; |
A curated list of AWS resources to prepare for the AWS Certifications
A curated list of awesome AWS resources you need to prepare for the all 5 AWS Certifications. This gist will include: open source repos, blogs & blogposts, ebooks, PDF, whitepapers, video courses, free lecture, slides, sample test and many other resources.