Return-Path: Delivered-To: apmail-ofbiz-user-archive@www.apache.org Received: (qmail 94999 invoked from network); 15 Nov 2010 12:24:37 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 15 Nov 2010 12:24:37 -0000 Received: (qmail 22423 invoked by uid 500); 15 Nov 2010 12:25:08 -0000 Delivered-To: apmail-ofbiz-user-archive@ofbiz.apache.org Received: (qmail 22294 invoked by uid 500); 15 Nov 2010 12:25:08 -0000 Mailing-List: contact user-help@ofbiz.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@ofbiz.apache.org Delivered-To: mailing list user@ofbiz.apache.org Received: (qmail 22286 invoked by uid 99); 15 Nov 2010 12:25:07 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Nov 2010 12:25:07 +0000 X-ASF-Spam-Status: No, hits=0.7 required=10.0 tests=RCVD_IN_DNSWL_NONE,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [216.40.44.86] (HELO smtprelay.hostedemail.com) (216.40.44.86) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 15 Nov 2010 12:24:59 +0000 Received: from filter.hostedemail.com (ff-bigip1 [10.5.19.254]) by smtprelay06.hostedemail.com (Postfix) with SMTP id 84BA12503628 for ; Mon, 15 Nov 2010 12:24:37 +0000 (UTC) X-Panda: scanned! X-Session-Marker: 6D61696C696E676C69737440616E7477656273797374656D732E636F6D X-Filterd-Recvd-Size: 1825 Received: from [192.168.2.11] (unknown [180.180.178.97]) (Authenticated sender: mailinglist@antwebsystems.com) by omf05.hostedemail.com (Postfix) with ESMTP for ; Mon, 15 Nov 2010 12:24:35 +0000 (UTC) Subject: Re: Aggregate Function From: Hans Bakker To: user@ofbiz.apache.org In-Reply-To: <1289822678513-3042946.post@n4.nabble.com> References: <1289714100670-3041512.post@n4.nabble.com> <4CDFC303.5040807@free-man.net> <1289751286818-3041836.post@n4.nabble.com> <4CE07571.30706@free-man.net> <1289822678513-3042946.post@n4.nabble.com> Content-Type: text/plain; charset="UTF-8" Date: Mon, 15 Nov 2010 19:24:32 +0700 Message-ID: <1289823872.2533.4.camel@hans-laptop> Mime-Version: 1.0 X-Mailer: Evolution 2.28.3 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org How about looking at what is already there? have a look in: applications/order/entitydef/entitymodel_olap.xml there the sales are already defined, perhaps you can improve on that? why people always want to build new and not improve what is already there? Regards, Hans On Mon, 2010-11-15 at 04:04 -0800, smithav wrote: > I am using the datawarehouse model BI. I am using the already existing Date > and Currency dimensions. I have defined Product, Customer, Location,Slaes > dimensions in addition to them. Here Sales is a fact table. It contains > foreign keys of all the dimension tables along with a field called sales. I > have to now write a query that either takes yrs or location as input from > user and gives the aggregate sales as output for that period or particular > location respectively. -- Ofbiz on twitter: http://twitter.com/apache_ofbiz Myself on twitter: http://twitter.com/hansbak Antwebsystems.com: Quality services for competitive rates.