SQL Server – Various methods to generate unique number sequence
Hi all, Friends, most of the time we used ranking function like ROW_NUMBER() when it required to generate unique number...
2015-09-28
650 reads
Hi all, Friends, most of the time we used ranking function like ROW_NUMBER() when it required to generate unique number...
2015-09-28
650 reads
HI friends, in some working scenario or during interviews we got the task to find the running totals of a...
2015-09-14
604 reads
Hi friends, I was working on a scenario in which I need to assign a unique values to a column....
2015-09-08
617 reads
Hi friends, in our day to day work we used SELECT…INTO clause to create replica of a table for different...
2015-08-03
662 reads
Hi friends, As you all know that SQL Server CTP2 has released with new great features. Here is the list of...
2015-07-26
669 reads
Sys.dm_exec_query_stats is most commonly used DMO used by DBA and developers to find out the information about queries involving query...
2015-07-25
645 reads
In SQL Server 2014 a new feature In-Memory OLTP was introduced which was referred as ‘Hekaton’. This feature was introduced...
2015-07-23
733 reads
Hi friends, today I will get you introduced with another new feature of SQL Server 2016 i.e. Temporal Tables. SQL...
2015-07-23 (first published: 2015-07-20)
3,093 reads
Hi friends, today we will continue with Query Store in SQL Server 2016. In previous blog we learnt about what...
2015-07-17
1,102 reads
Hi friends, in next few blogs we will explore another new feature named Query Store which gets introduced in SQL...
2015-07-16
704 reads
By Steve Jones
This value is something that I still hear today: our best work is done...
By gbargsley
Have you ever received the dreaded error from SQL Server that the TempDB log...
By Chris Yates
Artificial intelligence is no longer a distant concept. It is here, embedded in the...
You need line editing for books! A line editor smooths out your writing, sentence by...
We have a BI-application that connects to input tables on a SQL Server 2022...
At work we've been getting better at writing what's known as GitHub Actions (workflows,...
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; goWhat is the result? See possible answers