Jonathan Roberts


Technical Article

A DateRange Table Valued function

The function is an inline table-valued function (or sometimes called a parameterised view) so it can be used just like a view or a table but needs parameters. It generates a single-column table of datetime2 with rows differing by any multiple of any of the dateparts that SQL Server provides.

5 (6)

2019-08-29 (first published: )

2,318 reads

Blogs

Daily Coping 28 Oct 2021

By

I started to add a daily coping tip to the SQLServerCentral newsletter and to...

The DBA as a helpdesk.

By

Every one and again you will see people asking What skill do you think...

What’s my MAC Address in a Command Prompt?–#SQLNewBlogger

By

Another post for me that is simple and hopefully serves as an example for...

Read the latest Blogs

Forums

Update table FirstName & LastName from Email addresses

By DaveBriCam

I have a table with three fields, FirstName, LastName and EmailAddress. The EmailAddress field...

SQL Instance Aliases - Urgent assistance needed please

By Brandie Tarvin

I have a migration problem. I cannot get my SQL Server instance aliases to...

Error connecting using AlwaysON Listener

By Arsh

Dear Friends, I have a 2-node Read-Scale Always ON Availability Group to which I...

Visit the forum

Ask SSC

SQL Server Q&A from the SQLServerCentral community

Get answers