Update of /cvsroot/monetdb/pathfinder/compiler/include
In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv4837/compiler/include
Modified Files:
Tag: M5XQ
algebra.h
Log Message:
propagated changes of Friday Jun 12 2009 - Monday Jun 15 2009
from the development trunk to the M5XQ branch
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2009/06/12 - tsheyar: compiler/include/algebra.h,1.113
-- Replaced aggregate operators count, min, max, avg, sum, prod, seqty1,
and all in the algebra by a single aggregate operator ``aggr''
that can handle multiple aggregates. The aggregate entries
are of kind count, min, max, avg, sum, prod, seqty1, all, and dist.
-- Added new aggregate kind ``dist'' that allows to represent group by
columns that functionally depend on the partitioning criterion
in the result of the grouping aggregate.
-- Added rewrite that merges aggregates.
-- Added rewrite that removes superfluous aggregates.
-- Added rewrite that pushes a rank operator through an aggregate.
-- Extended the XML import to cope with the old
as well as the new representation of aggregates.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
U algebra.h
Index: algebra.h
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/compiler/include/algebra.h,v
retrieving revision 1.111.2.1
retrieving revision 1.111.2.2
diff -u -d -r1.111.2.1 -r1.111.2.2
--- algebra.h 20 May 2009 11:09:51 -0000 1.111.2.1
+++ algebra.h 15 Jun 2009 12:47:16 -0000 1.111.2.2
@@ -457,6 +457,29 @@
};
typedef enum PFalg_doc_tbl_kind_t PFalg_doc_tbl_kind_t;
+/* ................ aggregate specification ................. */
+
+enum PFalg_aggr_kind_t {
+ alg_aggr_dist /**< aggregate of a column that functionally
+ depends on the partitioning column */
+ , alg_aggr_count /**< count aggregate */
+ , alg_aggr_min /**< minimum aggregate */
+ , alg_aggr_max /**< maximum aggregate */
+ , alg_aggr_avg /**< average aggregate */
+ , alg_aggr_sum /**< sum aggregate */
+ , alg_aggr_seqty1 /**< sequence type matching for `1' occurrence */
+ , alg_aggr_all /**< all existential quantifier */
+ , alg_aggr_prod /**< product aggregate */
+};
+typedef enum PFalg_aggr_kind_t PFalg_aggr_kind_t;
+
+struct PFalg_aggr_t {
+ PFalg_aggr_kind_t kind; /**< aggregate kind */
+ PFalg_col_t res; /**< result column */
+ PFalg_col_t col; /**< input column */
+};
+typedef struct PFalg_aggr_t PFalg_aggr_t;
+
/* ............. document fields specification .............. */
enum PFalg_doc_t {
@@ -640,6 +663,18 @@
char * PFalg_fun_str (PFalg_fun_t fun);
/**
+ * Print aggregate kind
+ */
+char * PFalg_aggr_kind_str (PFalg_aggr_kind_t kind);
+
+/**
+ * Construct an aggregate entry.
+ */
+PFalg_aggr_t PFalg_aggr (PFalg_aggr_kind_t kind,
+ PFalg_col_t res,
+ PFalg_col_t col);
+
+/**
* Construct a predicate.
*/
PFalg_sel_t PFalg_sel (PFalg_comp_t comp,
------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
Monetdb-pf-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-pf-checkins