sql.snippet.BuildExecutionSummaryStep

PHOTO EMBED

Sun Feb 06 2022 14:27:49 GMT+0000 (UTC)

Saved by @rick_m #sql

<?xml version="1.0" encoding="utf-8"?>
<CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
  <CodeSnippet Format="1.0.0">
    <Header>
      <Title>bess - BuildExecutionSummaryStep</Title>
      <Description>executionplan step</Description>
      <Author>Rick M</Author>
      <Shortcut />
      <SnippetTypes>
        <SnippetType>Expansion</SnippetType>
      </SnippetTypes>
    </Header>
    <Snippet>
      <Code Language="SQL"><![CDATA[
PRINT ' ';
PRINT '--------------------------------------------------';
PRINT ' ';
SET @stepdescription = '';
SET @executionsummary = @executionsummary + CHAR(13) + ' - ' + @stepdescription;
PRINT CONVERT(VARCHAR(50), @step) + ') ' + @stepdescription;
PRINT ' ';
IF @step = @step
BEGIN
	--------------------------------------------------------
	--START

	SELECT 1;

	--END
	--------------------------------------------------------
END
PRINT ' ';
PRINT 'END ' + CONVERT(VARCHAR(50), @step) + ') ' + @stepdescription + ' : ' + CONVERT(VARCHAR, GETDATE() - @started, 108);
SET @step += 1;
PRINT ' ';
PRINT '--------------------------------------------------';
]]></Code>
    </Snippet>
  </CodeSnippet>
</CodeSnippets>
content_copyCOPY