External Article

SQL GROUP BY Basics

It sometimes pays to go back and look at what you think you already know about SQL. Joe Celko gives a quick revision of the GROUP BY and HAVING clauses in SQL that are the bedrock of any sort of analysis of data, and comes up with some nuggets that may not be entirely obvious.

Blogs

KDA: Echoes of Deception - Case 6

By

A cryptic message, a book cipher hidden in art provenance records, and a trail...

Capturing My Own Metrics: #SQLNewBlogger

By

A customer was trying to compare two tables and capture a state as a...

Red Flags in Your Query (T-SQL Tuesday #200)

By

When I'm looking at a query, I bet it's bad if I see... a...

Read the latest Blogs

Forums

ALAMAT KANTOR BCA KCU KISARAN TLP/WA 08218200174

By R4nt4u

Telp Cso: (0821)8200174 Jl. Cokro Aminoto No.28, Kisaran Kota, Kec. Kota Kisaran Barat, Kabupaten...

ALAMAT BCA KCU PEMATANG SIANTAR TLP/WA 08218200174

By layanan_Bca88

Telp Cso: (0821)8200174 Jl. Merdeka No.39, Proklamasi, Kec. Siantar Bar., Kota Pematang Siantar, Sumatera...

ALAMAT KANTOR BCA KCU ASIA TLP/WA 08218200174

By m4rt1n4

Telp Cso: (0821)8200174 Jl. Asia, Simpang, Jl. Bakaran Batu No.1 C, Sei Rengas II,...

Visit the forum

Question of the Day

BIT_COUNT II

In SQL Server 2025, I have a table (dbo.UserPermission) that contains this data:

UserID  UserPermissions
15
23
37
4       NULL
What is returned when I run this code:
select bit_count(UserPermissions) as PermissionCount
from dbo.UserPermission
where UserID = 4;

See possible answers