Changing SQL Server Agent Jobs Ownership: Who should own SQL Server Agent Jobs
I writing this blog post as a result of the following two questions, which I’ve been asked by one of...
2014-04-04
2,125 reads
I writing this blog post as a result of the following two questions, which I’ve been asked by one of...
2014-04-04
2,125 reads
After power surge last night, I realized few availability databases (also known as a “database replica”) have an unhealthy data...
2014-04-02
4,160 reads
One of the most important tasks on a DBA’s to-do list is backing up databases on a regular basis. This...
2014-03-16
1,302 reads
Today, we experienced performance issues with some of the SSRS reports that were deployed as part of the latest application/database...
2014-03-13
3,226 reads
Today, I received an email from the developer asking if there is a better way instead of the COUNT (*) Transact-SQL...
2014-03-06
1,410 reads
One of the key tasks of a DBA is to maintain the database indexes and make sure they are not...
2014-02-23
2,963 reads
Problem
Today, one of the developers come to me and asked me the question that is there any T-SQL function that...
2014-02-23
46,577 reads
Here is the simple query that returns basic information about all tables in a database that are partitioned:
SELECT SCHEMA_NAME([schema_id]) AS...
2014-02-17
1,506 reads
You can use the following two DMVs to give you that information:
sys.dm_exec_cached_plans – You can use this dynamic management view to...
2014-02-17
1,039 reads
We have about 200 user databases in which we have the full-text search enabled and these databases contain several tables....
2014-01-27
1,685 reads
By Chris Yates
The New Arena of Leadership The role of the Chief Data Officer is no...
Presenting you with an updated version of our sp_snapshot procedure, allowing you to easily...
SELECT * feels convenient, but in SQL Server it bloats I/O, burns network bandwidth,...
I've noticed several instances of what looks like a recursive insert with the format:...
Comments posted to this topic are about the item Cleaning Up the Cloud
Comments posted to this topic are about the item The Maximum Value in the...
I have a table with this data:
TravelLogID CityID StartDate EndDate 1 1 2025-01-01 2025-01-06 2 2 2025-01-01 2025-01-06 3 3 2025-01-01 2025-01-06 4 4 2025-01-01 2025-01-06 5 5 2025-01-01 2025-01-06I run this code:
SELECT IDENT_CURRENT('TravelLog')I get the value 5 back. Now I do this:
SET IDENTITY_INSERT dbo.TravelLog ON INSERT dbo.TravelLog ( TravelLogID, CityID, StartDate, EndDate ) VALUES (25, 5, '2025-09-12', '2025-09-17') SET IDENTITY_INSERT dbo.TravelLog OFFI now run this code.
DBCC CHECKIDENT(TravelLog) GO INSERT dbo.TravelLog ( CityID, StartDate, EndDate ) VALUES (4, '2025-10-14', '2025-10-17') GOWhat is the value for TravelLogID for the row I inserted for CityID 4 and dates starting on 14 Oct 2025? See possible answers