Sql-server – How to separate a number from 3 digits to 3 digits by comma in sql server?

conversationnumber formattingsql server

For example, I want to convert the number.

select convert(1354256,money) salMoney

result:

1354256

convert to

1,354,256

Best Answer

use this function sql server (MSSQL)

select format(1354256,'N0')