sql - Query Optimization for below query -
can me optimize below query?
select distinct p.providerid ,p.npi ,p.firstname ,p.lastname ,c.servicedatestart ,cptcodecms ,mf.calendar_year ,year(c.servicedatestart) erviceyear ,c.units ,l.zip mapping.memberprofpercentage inner join library.dbo.tbl_cpt_medicareprof mf on cptcodecms = mf.state_cptcodecms join cpmrep.charges c on mf.calendar_year <> year(c.servicedatestart) join cpmrep.providers p on c.renderingproviderid = p.providerid join cpmrep.locations l on c.locationid = l.locationid cptcodecms in ( '49080' ,'76930' ,'75650' ,'73500' ,'75961' ,'72069tc' ,'73520tc' ,'76645' ,'99232' ,'64622' ,'45388' ,'43269' ,'78223' ,'73550' ,'45389' ,'9330626' ,'95903' ,'43268' ,'45347' ,'32422' ,'32421' ,'37620' ,'73510' ,'92982' )
Comments
Post a Comment