sql server 2008 - Remove the Null Value from the result generated from MAX() used in query sql -


when use query:

select max(dt_logdate)   ums_logentry_dtl  c_inputmode='r' , vc_deviceid=10 

the table gives maximum date, if condition not satisfied returns data table null. there null row. need empty data table. how remove null on noresult?

you use having clause:

select max(dt_logdate)   ums_logentry_dtl  c_inputmode='r' , vc_deviceid=10 having max(dt_logdate) not null 

Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -