July 2025 Discount: Comprehensive Database Performance Health Check | Testimonials

Home
  • Consulting
  • Training
  • Free Videos
  • All Articles
    • Interview Questions and Answers
    • SQL Tips and Tricks
    • SQL Performance
    • SQL Puzzle
    • Big Data
    • Blog Stats
    • SQL Books
    • Search SQLAuthority
  • Downloads
  • Hire Me
  • Health Check

SQL SERVER – Converting Stored Procedure into Table Valued Function

September 17, 2009
Pinal Dave
SQL, SQL Performance, SQL Server, SQL Tips and Tricks
SQL Function, SQL Stored Procedure
In one of my recent articles, I mentioned the use of Table Valued Function (TVF) instead of Stored Procedure (SP). I received a follow up email asking what type of SP can be converted into a TVF. This is indeed a very interesting question! In fact, not all the SPs…
Read More

SQL SERVER – Get Time in Hour:Minute Format from a Datetime – Get Date Part Only from Datetime

August 6, 2009
Pinal Dave
SQL Tips and Tricks
SQL DateTime, SQL Function, SQL Scripts, SQL Server

I have seen scores of expert developers getting perplexed with SQL Server in finding time only from datetime datatype. Let us have a quick glance look at the solution. Let us learn about how to get Time in Hour:Minute Format from a Datetime as well as to get Date Part Only from Datetime.

Read More

SQL SERVER – List All Missing Identity Values of Table in Database

July 27, 2009
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
SQL Function, SQL Identity, SQL Scripts, SQL Stored Procedure
The best part of any blog is when readers ask each other questions. Better still, is when a reader takes the time to provide a detailed response. A few days ago, one of my readers, Yasmin, asked a very interesting question: How we can find the list of tables whose…
Read More

SQL SERVER – Get Last Running Query Based on SPID

July 19, 2009
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
SQL Function, SQL Scripts, SQL Server DBCC, SQL System Table
We often need to find the last running query or based on SPID need to know which query was executed. SPID is returns sessions ID of the current user process. The acronym SPID comes from the name of its earlier version, Server Process ID. To know which sessions are running…
Read More

SQL SERVER – Delete Duplicate Rows

June 23, 2009
Pinal Dave
SQL Video
Duplicate Records, SQL Function, SQL Scripts, SQL Server

I had previously penned down two popular snippets regarding deleting duplicate rows and counting duplicate rows. Today, we will examine another very quick code snippet where we will delete duplicate rows using CTE and ROW_NUMBER() feature of SQL Server 2005 and SQL Server 2008.

Read More

SQL SERVER – Connect Item – Vote for Feature Request Function TRIM

June 3, 2009
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
SQL Function
Till date, I have met the SQL Server Product Team twice: first time at SQL Server MVP Meet, Seattle, and second time at TechEd India 2009, Hyderabad. At both the times, I have put forth one request to the product team regarding implementing of function Trim(). As per my opinion,…
Read More

SQL SERVER – Difference Between Candidate Keys and Primary Key

May 30, 2009
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
SQL Constraint and Keys, SQL Function, SQL Scripts
Let us first try to grasp the definition of the two keys. Candidate Key – A Candidate Key can be any column or a combination of columns that can qualify as unique key in database. There can be multiple Candidate Keys in one table. Each Candidate Key can qualify as…
Read More
Previous 1 … 32 33 34 35 36 37 38 … 52 Next
  • SQL Interview Q & A
  • Testimonials
  • Search
  • Privacy Policy

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

Go to mobile version