SQL Server T-SQL CASE Statement Examples
This tip will teach you when and how you can use CASE in T-SQL statements with several code examples to give you a better understanding.
2021-05-14
This tip will teach you when and how you can use CASE in T-SQL statements with several code examples to give you a better understanding.
2021-05-14
You’ve submitted thousands of bug reports and feature requests at feedback.azure.com. Brent Ozar goes through what you’ve voted as the top 10 requests right now.
2021-05-14
In this tip we look at the Sequence Number feature in SQL Server and compare it to the use of identity columns.
2021-05-10
How to use a SQL random data generator to fill SQL Server tables with realistic test data, to shift left database unit testing, integration testing and performance testing so that it is performed during the early stages of database development.
2021-05-03
Check out this SQL Server function that can return memory usage information for a SQL Server instance such as the amount of memory SQL Server is using and available memory on the machine.
2021-05-03
In this article, Edward Pollack explains the benefits of a SQL Server data dictionary and how to build one.
2021-04-29
In this article we cover interesting facts about the hidden resource database in SQL Server and how this is used by SQL Server.
2021-04-28
In this article we cover the topic of data wrangling which is steps you can take to cleanup and validate data prior to data analysis.
2021-04-23
Security roles can simplify permissions in SQL Server. In this article, Greg Larsen explains fixed server and database roles.
2021-04-22
The 2021 State of Database Monitoring survey is now open, and we want to know how you’re currently tackling your server, instance, and database monitoring. By taking part, you’ll contribute to the sole industry-wide report on database monitoring, and provide insights into how SQL Server professionals manage their estates and what challenges they face. Plus, you’ll receive an advanced copy of the report and entry to a prize draw to win a $500 Amazon voucher.
2021-04-19
By Vinay Thakur
These days everything is changing to AI World, IT roles are getting changed and...
I’m doing a small series on indexing basics for SQL Server, and on May...
PlanTrace: Stop Reading Redshift EXPLAIN Plans. Start Seeing Them Introducing PlanTrace — a free, browser-based...
We suffered a SPAM attack from May 1-6, which unfortunately corresponded with time off...
Hi to all We have situation at a client where someone is illegally changing...
Hi to all We have situation at a client where someone is illegally changing...
I have this data in a table called dbo.NFLTeams
TeamID TeamName City YearEstablished ------ -------- ---- --------------- 1 Cowboys Dallas 1960 2 Eagles Philadelphia 1933 3 Packers Green Bay 1919 4 Chiefs Kansas City 1960 5 49ers San Francisco 1946 6 Broncos Denver 1960 7 Seahawks Seattle 1976 8 Patriots New England 1960If I run this code, how many rows are returned?
SELECT TOP 2
json_objectagg('Team' : TeamName)
FROM dbo.NFLTeams;
See possible answers