A
Andrew Banks
I'm outputting data from a SQL server database to a web form (C#).
How can I detect if a value is null in the database?
Thanks
How can I detect if a value is null in the database?
Thanks
Wes Brown said:Andrew,
To check if a value is null compare to DBNull.Value.
Ex:
if (myTable.Rows[0][0] == DBNull.Value)
...
I'm outputting data from a SQL server database to a web form (C#).
How can I detect if a value is null in the database?
Thanks
Wes Brown said:Andrew,
To check if a value is null compare to DBNull.Value.
Ex:
if (myTable.Rows[0][0] == DBNull.Value)
...
I'm outputting data from a SQL server database to a web form (C#).
How can I detect if a value is null in the database?
Thanks
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.