Separating Numbers into Groups of Three in SQL Server

Hello everyone,

In this article, I will give information about dividing numbers into groups of three in SQL Server.

In SQL Server, in some cases we may want to separate our numbers into triple digits to make them more readable.

You can easily do this with the help of the code below.

DECLARE @Amount INT;
SET @Amount = 65536;
SELECT FORMAT(@Amount, '#,#') AS SegregatedEndStatus;

When you create and run the code, you will get a result like the one below.

Separating Numbers into Groups of Three in SQL Server

As you can see, our number has been divided into three digits.

Good luck to everyone in business and life.

 

176 Views

Yavuz Selim Kart

I try to explain what I know in software and database. I am still improving myself by doing research on many programming languages. Apart from these, I am also interested in Graphic Design and Wordpress. I also have knowledge about SEO and Social media management. In short, I am a determined person who likes to work hard.

You may also like...

Don`t copy text!