The stored procedure for command can return null.Is it correct way to check if the returned value is null or should I also check that obj is null?

```
object obj = command.ExecuteScalar();
int id = -1;
if (DBNull.Value == obj)
{
   id = Convert.ToInt32(obj );
}

```