Question: I need to store an CARD ID number in Database. So there is no calculation just a search of the ID and putting the value in Session as property in a class.

The is ID is always numeric and it's 12 positions.
e.g. 123456789012 and I would like to show on the screen in this format. 123.456.789.012 (every 3 digit a dot).

I tried a test and defined Decimal(12,0) in database and I have put this value in database: 555666777888

then I try to display on the screen I used this code (CardID is decimal):

```
  lblCardID.Text = ent.CardID.ToString("0:#,###")

```

but it shows on the screen like this: **555,666,77:7,888** 

where is the **colon (:)** coming from? 

question additional:
- What type shall use in MS SQL to store this value in Database. Decimal (12,0) or Nvarchar(12) ?

Answer: 
Try writing 

```
lblCardID.Text = ent.CardID.ToString("#,###")

```

You can user the `decimal(12,0)` or the `bigint` datatype. `bigint` requires one byte less (8 bytes total) per stored value.
If it's never going to be calculated on, I would store it as char(12).

Then in your code, split it with something like this and use the replace function to convert commas to dots:

`lblCardID.Text = ent.CardID.ToString("#,###").Replace(",", ".")`