Dallas DBAs

Blog Post

Where Is My SQL Server Errorlog?

If you need to find the SQL Server ErrorLog in a hurry and don’t want to spend 30 minutes drilling into every drive on the server: “I don’t watch...

2022-11-21 (first published: )

252 reads

Blog Post

SQL Server Registered Servers

Query multiple SQL Server instances at one time! Thanks for watching! Kevin3NF Follow @Dallas_DBAs
The post SQL Server Registered Servers appeared first on DallasDBAs.com.

2022-11-09 (first published: )

449 reads

Blog Post

SQL Server Best Practices

As a CIO or CTO, one of your primary responsibilities is to ensure that your organization’s data is managed effectively and efficiently. To do this, you need to have...

2022-09-14

26 reads

Blog Post

SQL Server Migration and Upgrade

(This post written by Jon Biggs (t), one of our Senior DBAs) We are currently performing migrations with upgrade of multiple-instance SQL Servers to new servers. The migrations are...

2022-03-22

40 reads

Blog Post

Group By Starting Characters

I was chatting with Jeff (b|t) on my team yesterday and the context escapes me but I had this thought: “Can you Group By the beginning characters, or a...

2021-10-29 (first published: )

503 reads

Blog Post

Do Full Backups Break Log Shipping?

TLDR: Nope. Keep on doing your full backups. Make sure that any databases you Log Ship are NOT also doing log backups in your SQL Maintenance Plans, Ola Jobs,...

2021-10-22 (first published: )

319 reads

Blog Post

How old are those stats?

SQL Server maintains a variety of stats about all sort of performance items. Index usage (or missing indexes) Query performance Corrupt pages Disk IO performance Way more than I...

2021-10-11 (first published: )

293 reads

Blogs

Why Optimize CPU for RDS SQL Server is a game changer

By

One feature that I have been waiting for years! The new announcement around optimize...

Performance tuning KubeVirt for SQL Server

By

Following on from my last post about Getting Started With KubeVirt & SQL Server,...

T-SQL Tuesday #193 – A Note to Your Past, and a Warning from Your Future

By

I haven’t posted in a while (well, not here at least since I’ve been...

Read the latest Blogs

Forums

Refactoring SQL Code

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Refactoring SQL Code, which is...

The Read Committed Snapshot Isolation behaviour

By Alessandro Mortola

Comments posted to this topic are about the item The Read Committed Snapshot Isolation...

Working with JSON/JSONB Data in PostgreSQL using Python

By sabyda

Comments posted to this topic are about the item Working with JSON/JSONB Data in...

Visit the forum

Question of the Day

The Read Committed Snapshot Isolation behaviour

I am currently working with Sql Server 2022 and AdventureWorks database. First of all, let's set the "Read Committed Snapshot" to ON:

use master;
go

alter database AdventureWorks set read_committed_snapshot on with no_wait;
go
Then, from Session 1, I execute the following code:
--Session 1
use AdventureWorks;
go

create table ##t1 (id int, f1 varchar(10));
go

insert into ##t1 values (1, 'A');
From another session, called Session 2, I open a transaction and execute the following update:
--Session 2
use AdventureWorks;
go

begin tran;
update ##t1 
set f1 = 'B'
where id = 1;
Now, going back to Session 1, what happens if I execute this statement?
--Session 1
select f1
from ##t1
where id = 1;
 

See possible answers