This month's discount Comprehensive Database Performance Health Check · Testimonials
SQLAuthority with Pinal Dave
Home
  • Consulting
    • Health Check
  • Free Videos
  • All Articles
    • AI
    • SQL Performance
    • SQL Tips and Tricks
    • Interview Questions and Answers
    • SQL Puzzle
    • SQL Video
    • SQLAuthority News
    • Personal
  • Books
  • Consulting
SQL SERVER - Correct Syntax for Stored Procedure SP

SQL SERVER – Correct Syntax for Stored Procedure SP

November 28, 2007
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Stored Procedure

What is the correct syntax for stored procedure code? Anything between BEGIN and END is part of the procedure, and anything after GO is not, as my examples show.

Read More
SQL SERVER - 2005 - List All Stored Procedure in Database

SQL SERVER – 2005 – List All Stored Procedure in Database

November 27, 2007
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Stored Procedure

Want to see all stored procedure in database at once? Run SELECT * FROM sys.procedures. This simple query works only with SQL Server 2005.

Read More
Two wooden trays of blue and pale stones, with one loose blue stone between them.

Multiset Intersection: Keep the Matching Duplicate Occurrences

November 24, 2007
Pinal Dave
SQL Tips and Tricks
SQL Function, SQL Joins, SQL Scripts, SQL Server

Multiset intersection keeps the duplicate count shared by both inputs rather than returning each common value once. I pair numbered occurrences to express that requirement. The result should contain the smaller count for each equivalent value.

Read More
SQL SERVER - Generate Incremented Linear Number Sequence

SQL SERVER – Generate Incremented Linear Number Sequence

November 21, 2007
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Server

A reader asked how to generate an incremented linear number sequence in SQL Server, like a sequence in Oracle. A short WHILE loop script does it.

Read More
Gouache painting: two river sluice gates stand side by side

DEGREES: Preserve Fractions When Converting Angles

November 20, 2007
Pinal Dave
SQL Tips and Tricks
SQL Datatype, SQL Function, SQL Scripts, SQL Server

DEGREES converts radians into degrees. An integer radian argument can narrow the output, while a float argument retains an approximate fractional degree value.

Read More
A gouache packing workshop pairs an open fitted framework with the matching solid pieces needed to fill it.

SQL SERVER – Generate Script with Data from Database – Database Publishing Wizard

November 16, 2007
Pinal Dave
SQL Tips and Tricks
DBA, SQL Backup and Restore, SQL Download, SQL Scripts

The Database Publishing Wizard scripted schema and data for SQL Server 2005-era transfers. I keep that workflow separate from current SSMS instructions.

Read More
Red, blue and gray felt hats share different levels of a wooden display shelf.

TOP WITH TIES: Keep Every Row at the Cutoff

November 14, 2007
Pinal Dave
SQL Tips and Tricks
SQL NULL, SQL Order By, SQL Scripts, SQL Server

TOP WITH TIES helps me keep equally qualified rows at a shortlist boundary. A unique ordering key changes that selection. Separate the cutoff rule from the final display order.

Read More
Previous 1 … 325 326 327 328 329 330 331 … 363 Next
  • Books
  • Testimonials
  • Privacy Policy

© 2006 – 2026 All rights reserved. pinal @ SQLAuthority.com