This file contains hidden or 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
/* | |
This script helps simulate deadlocks. Run the entire script in a SQL query window. It will continue running until stopped. | |
In the target script, insert a call to sp_simulatedeadlock where you want the deadlock to occur. | |
This stored procedure, also created below, causes the deadlock. | |
When you are done, stop the execution of this window and run the code in the cleanup section at the bottom. | |
*/ | |
SET NOCOUNT ON | |
IF OBJECT_ID('DeadlockTest') IS NOT NULL | |
DROP TABLE DeadlockTest |
This file contains hidden or 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
$url = "http://<url>?WSDL" | |
$name = "<Service Name>" | |
$namespace = "<Base Namespace>." + $name | |
$file = "$name.generated.cs" | |
echo "Generating service $name ($url)" | |
& "C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.6.1 Tools\SvcUtil.exe" /t:code $url /language:C# /n:"*,$namespace" /out:$file /noConfig /syncOnly | out-null | |
(Get-Content $file) | Foreach-Object {$_ -replace "(?<=public [\w\.]+(?:\[\])? \w+)(;)", " { get; set; }"} | Set-Content $file |
NewerOlder