how to use DataTable.Select() to select Null/ empty values?

前端 未结 2 1671
长情又很酷
长情又很酷 2021-02-04 04:05

My data table filled from db is having empty values in some cells.

The results database SP return has Null in them but in DataTable these values are appearing as \'\' or

2条回答
  •  独厮守ぢ
    2021-02-04 04:59

    For one column

    DataRow rows = DataTable.Select("[COLUMN 1]=''");
    

    For more than one column

    DataRow rows = DataTable.Select("[COLUMN 1]='' OR [COLUMN 2]=''");
    

提交回复
热议问题