1.To check if no data ,return value in sql query
selectCASE NewsItem WHEN null THEN 'No Data' ELSE NewsItem ENDFROM [NewsTable]
2.'CREATE/ALTER PROCEDURE' must be the first statement in a query batch.
3.To check null values
select case M_Distributor_Id when null then 0 else 1 end as flag
4.
IF EXISTS( SELECT Author FROM [News] WHERE NewsDate = NewsDate )
BEGIN5.
if(dr["DOB"] == DBNull.Value) {//Null value in DOB Column}else{//Not Null}
No comments:
Post a Comment