Subject Re: Query not finishing before rest of program runs
Author bou@altekcomputer.com
> What are you doing inside your procedure to capture the result of
the count
> query? I would expect something like
>
> create procedure Count_and_be_Damned
> returns (Expensive_Row_Count integer) as
> begin
> SELECT COUNT(Check_detail.CK_ID) Ck_id
> > FROM CHECK_DETAIL Check_detail
> > LEFT OUTER JOIN CHECK_MASTER Check_master
> > ON Check_detail.CK_ID = Check_master.CK_ID
> > WHERE (((Check_detail.CK_EMP_KEY = '003')
> > AND (Check_detail.CD_RECORD_CODE = '4')
> > AND (Check_detail.CK_RECORD_TOTAL_TYPE = 'C')
> > AND (Check_master.CK_CK_DATE BETWEEN '02/01/2001'
> >AND '02/28/2001')))
>
> into :Expensive_Row_Count;
> Suspend;
> END
>
> Then your application call can be
>
> SELECT Expensive_Row_Count from Count_and_be_Damned
>
>
> Helen
>
>
>
> All for Open and Open for All
> InterBase Developer Initiative ยท http://www.interbase2000.org
> _______________________________________________________

Hi Helen

Thanks for the help and the fast response but it was my mistake. I
had flagged a record wrong. This was one of those problems that are
so simple that they get overlooked and they take forever to find.

Thanks Again,
Bo