External Article

Practical SQL Server 2005 CLR Assemblies

One advantage of CLR assemblies is the ability to consume web services from within the database. This wouldn’t be easy with T-SQL, and would also require a lot of work in an unmanaged extended stored procedure. With .NET, it’s almost as simple as accessing a local DLL. There are just a couple of extra command-line utilities we need to run to be able to access web services from within a SQL assembly:

SQLServerCentral Article

Differential Backup Prediction

SQL Server 2000 has a rock solid backup scheme , but do you really need to run full backups every day? What if you could decide on the fly if it was more efficient for a full or a differential backup? Darwin Hatheway brings us the basis for a scheme that can predict the size of a differential backup by examining how much of the database has changed.

External Article

Try/Catch Block in SQL Server 2005

Server 2005 now supports a more programmable error trapping convention in T-SQL code. This error handling is known as the TRY/CATCH block. The TRY/CATCH block allows T-SQL to handling errors like other programming languages, such as Microsoft Visual C# and C++. In addition to the TRY/CATCH block, Microsoft has expanded the set of available system functions in SQL Server 2005 for returning error codes and messages when an error occurs in your T-SQL code. This article will explore the new TRY/CATCH block and explain the new system functions for returning error codes and messages.

External Article

SQL Server and .NET Training and Career Development

In the past, it was common for an employer to work with their employees and pay to keep their skills current. While this still happens, in this age of high employee (and employer) turnover, many companies are more circumspect about how much they will spend to keep their employees keep up-to-date. At the end of the day, it is your responsibility to make sure this happens and there are many good reasons why you should strive to do so and many ways in which you can do it.

SQLServerCentral Article

SQL Server Alerts In C++ Builder

SQL Server has a great alerting mechanism for letting DBAs know when some event has occurred, but adding this notification to clients is a little more difficult. New author Stas Vasiljev brings us an extended stored procedure that has has used to allow clients to receive a broadcast when data has changed on a server.

Blogs

Troubleshooting TempDB Log Full Errors When SSMS Won’t Connect

By

Have you ever received the dreaded error from SQL Server that the TempDB log...

Accelerating AI with Confidence: Why Microsoft Purview is Key to Responsible Innovation

By

Artificial intelligence is no longer a distant concept. It is here, embedded in the...

The Mystery of SQL Server 2025’s New Tricks – Scooby Dooing Episode 5

By

Every Scooby-Doo mystery starts with a haunted house, a strange villain, and a trail...

Read the latest Blogs

Forums

The Tightly Linked View

By Steve Jones - SSC Editor

Comments posted to this topic are about the item The Tightly Linked View

Build a Test Lab of SQL Server 2025 on Windows Server 2025 using Hyper-V Virtual Machines

By Aleksey Vitsko

Comments posted to this topic are about the item Build a Test Lab of...

Remembering Phil Factor

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Remembering Phil Factor

Visit the forum

Question of the Day

The Tightly Linked View

I try to run this code on SQL Server 2022. All the objects exist in the database.

CREATE OR ALTER VIEW OrderShipping
AS
SELECT cl.CityNameID,
       cl.CityName,
       o.OrderID,
       o.Customer,
       o.OrderDate,
       o.CustomerID,
       o.cityId
 FROM dbo.CityList AS cl
 INNER JOIN dbo.[Order] AS o ON o.cityId = cl.CityNameID
GO
CREATE OR ALTER FUNCTION GetShipCityForOrder
(
    @OrderID INT
)
RETURNS VARCHAR(50)
WITH SCHEMABINDING
AS
BEGIN
    DECLARE @city VARCHAR(50);
    SELECT @city = os.CityName
    FROM dbo.OrderShipping AS os
    WHERE os.OrderID = @OrderID;
    RETURN @city;
END;
go
What is the result?

See possible answers