May 17, 2010 at 5:26 am
Hi all :-),
I have the below query in a stored procedure. When I am executing the stored procedure it is showing zero (0) results. If I run it from backend with testcode (creating temp tables using Stored procedure print queries), it is showing results. Is there any functionality problem araising while executing procedure? Please help me.
select c.[value], c.vdescr,r.fcount, d.rcount, e.ccount from
[10.10.6.30].util_db.dbo.lookup_type c left join
(select b.actid,isnull(count(distinct a.id),0) as fcount from #trans a
inner join clien_db.dbo.CC_645_GN b on a.id=b.id group by b.actid) r
on r.actid=c.[value]
inner join #rcounts d on 1=1 inner join #ccounts e on 1=1 where
e.hstatus='n' and d.hstatus='n' order by vdescr
Thanks in advance.
May 17, 2010 at 5:18 pm
You're using 3 temporary tables in your query -- what is populating those tables when you run this in each of the two scenarios you mention?
Rob Schripsema
Propack, Inc.
May 18, 2010 at 4:38 am
Can you please post some test data?
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply