Ignoring NULLs with FIRST_VALUE
Watch this week's video on YouTube
The SQL Server FIRST_VALUE function makes it easy to return the "first value in an ordered set of values."
The problem is that if that...
2018-08-28
28 reads
Watch this week's video on YouTube
The SQL Server FIRST_VALUE function makes it easy to return the "first value in an ordered set of values."
The problem is that if that...
2018-08-28
28 reads
Watch this week's video on YouTube
Last week I needed to write a recursive common table expression. I've written them before, but it's been a while and needed to visit...
2018-08-21
25 reads
Watch this week's video on YouTube
Last week I needed to write a recursive common table expression. I've written them before, but it's been a while and needed to visit...
2018-08-21
20 reads
Watch this week’s post on YouTube
One of the things that the SQL Server query optimizer does is determine how to...
2018-08-16 (first published: 2018-07-31)
4,017 reads
This post is a response to this month's T-SQL Tuesday #105 prompt by Wayne Sheffield. T-SQL Tuesday is a way for the SQL Server community to share ideas about...
2018-08-14
20 reads
This post is a response to this month's T-SQL Tuesday #105 prompt by Wayne Sheffield. T-SQL Tuesday is a way for the SQL Server community to share ideas about...
2018-08-14
8 reads
Watch this week's video on YouTube
I write a lot of dynamic SQL and frequently encounter variables that contain many characters:
DECLARE @LongValue NVARCHAR(MAX) = CAST('' AS NVARCHAR(MAX)) +
N'SELECT
...
2018-08-07
33 reads
Watch this week's video on YouTube
I write a lot of dynamic SQL and frequently encounter variables that contain many characters:
DECLARE @LongValue NVARCHAR(MAX) = CAST('' AS NVARCHAR(MAX)) +
N'SELECT
...
2018-08-07
22 reads
Click here to watch this week’s video on YouTube.
I write a lot of dynamic SQL and frequently encounter variables that...
2018-08-07
392 reads
Watch this week's video on YouTube
One of the things that the SQL Server query optimizer does is determine how to retrieve the data requested by your query.
Usually it does...
2018-07-31
25 reads
I wanted to create an Amazon Aurora PostgreSQL database on AWS using Terraform. The...
By Steve Jones
This is a great image from the 2012 book. You don’t need to ready...
By Brian Kelley
Annually, the IIA Palmetto Chapter puts on a 1 day on-line event in conjunction...
Comments posted to this topic are about the item The Valuable AI Project
Comments posted to this topic are about the item A Fun Friday
Comments posted to this topic are about the item Adding Bits III
I have a table, dbo.bittest, where I am testing an application response. This has this structure:
CREATE TABLE [dbo].[BitTest] ( [insertdate] [datetime] NULL CONSTRAINT [DF__BitTest__insertd__300F11AC] DEFAULT (getdate()), [a] [bit] NULL ) ON [PRIMARY] GOMy application runs this code:
INSERT dbo.BitTest
(
insertdate,
a
)
VALUES
(DEFAULT, 9)
GO
What gets inserted for the most recent date/time value? See possible answers