Subject | Re: [firebird-support] Views and where clauses |
---|---|
Author | Arno Brinkman |
Post date | 2004-11-04T22:56:10Z |
Hi,
outside.
For a "aggregate view" the where clause is going into the having clause,
because you could be filtering on a aggregate function (or expression which
contains it).
Regards,
Arno Brinkman
ABVisie
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Firebird open source database (based on IB-OE) with many SQL-99 features :
http://www.firebirdsql.org
http://www.firebirdsql.info
http://www.fingerbird.de/
http://www.comunidade-firebird.org/
Support list for Interbase and Firebird users :
firebird-support@yahoogroups.com
Nederlandse firebird nieuwsgroep :
news://80.126.130.81
> First a simple question - are views capable of using indexes whenViews that contain aggregates and unions cannot use a where clause from the
> selected from with a where clause?
> The view would be defined as such:
>
> Create view A_Max (Column1, column2, column3, max_create_date) as
> select
> column1, column2, column3, max(created_date)
> from
> a
> group by
> column1, column2, column3;
outside.
For a "aggregate view" the where clause is going into the having clause,
because you could be filtering on a aggregate function (or expression which
contains it).
Regards,
Arno Brinkman
ABVisie
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Firebird open source database (based on IB-OE) with many SQL-99 features :
http://www.firebirdsql.org
http://www.firebirdsql.info
http://www.fingerbird.de/
http://www.comunidade-firebird.org/
Support list for Interbase and Firebird users :
firebird-support@yahoogroups.com
Nederlandse firebird nieuwsgroep :
news://80.126.130.81