is there alternative following query return me records having 0 documents?? please me.
select * ( select row_number() over( order parentid ) rownumber_ps, upper(hostapplicationlocaldata.parentid) asparentid, count(document.id) documents hostapplicationlocaldata left outer join document on hostapplicationlocaldata.id=document.hostapplicationlocaldata_id hostapplicationlocaldata.transactiontype_id = 1 , (document.removed=0 or document.hostapplicationlocaldata_id null) , hostapplicationlocaldata.company_id = 9000 , (sharepointuri not null or ((sharepointuri isnull , content_id not null ) or ((hostapplicationlocaldata_id not null andhostapplicationlocaldata_id != 0 , content_id isnull)) ) ) group hostapplicationlocaldata.parentid )q documents = 0
Comments
Post a Comment