Insert a null value to an int column in sql server

前端 未结 3 1064
闹比i
闹比i 2021-01-25 07:10

I have a subroutine to insert a record to sql server table. The code:

    public void Insert_Met(int Counts, char Gender)
    {
        Dictionary

        
3条回答
  •  攒了一身酷
    2021-01-25 07:42

    Following statement will always produce not null value

    int counts = Convert.ToInt32(null); // Result is 0
    

提交回复
热议问题