Subject | Re: [IBO] Re: Filter Problems |
---|---|
Author | Helen Borrie |
Post date | 2005-02-11T03:00:23Z |
At 12:19 AM 11/02/2005 +0000, you wrote:
criteria (i.e. the WHERE clause). not the grouping criteria.
The only way you could wangle a filter like this would be to put the query
into a view, with the count as a legal column name, then filter the view on
that column.
Helen
>Let me expound on how this is useful and what it would be similar toIt's not valid for a filter. Filtering is done on the basic of the search
>in SQL
>
>it would be like writing the following
>
>SELECT Count(*), PRODUCT_CODE, SUM(BALANCE) BAL FROM ACCOUNTS GROUP
>BY PRODUCT_CODE HAVING Count(*) > 10
>
>How this is useful is that you really only want to see the sum of
>the balance for products that have a count over 10.
>
>Now I COULD go in and dynamically rewrite the SQL statement.
>However this is a bit inefficient when I can query all of the
>records and then just filter the results on the screen.
>
>Now if applying a filter on TIBOQuery causes the dataset to be
>requiried then I may as well just dynamically write the SQL
>statement.
>
>But I would hope that the Filter would work to reduce the records I
>am getting back.
criteria (i.e. the WHERE clause). not the grouping criteria.
The only way you could wangle a filter like this would be to put the query
into a view, with the count as a legal column name, then filter the view on
that column.
Helen