Return-Path: X-Original-To: apmail-hadoop-user-archive@minotaur.apache.org Delivered-To: apmail-hadoop-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 44FE59BE4 for ; Fri, 5 Oct 2012 07:16:19 +0000 (UTC) Received: (qmail 9280 invoked by uid 500); 5 Oct 2012 07:02:58 -0000 Delivered-To: apmail-hadoop-user-archive@hadoop.apache.org Received: (qmail 7797 invoked by uid 500); 5 Oct 2012 07:02:55 -0000 Mailing-List: contact user-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hadoop.apache.org Delivered-To: mailing list user@hadoop.apache.org Received: (qmail 7759 invoked by uid 99); 5 Oct 2012 07:02:54 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 05 Oct 2012 07:02:54 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of funnlearnforkids@gmail.com designates 209.85.223.176 as permitted sender) Received: from [209.85.223.176] (HELO mail-ie0-f176.google.com) (209.85.223.176) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 05 Oct 2012 07:02:49 +0000 Received: by mail-ie0-f176.google.com with SMTP id k11so3618619iea.35 for ; Fri, 05 Oct 2012 00:02:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=E0ix1tcu5CUu/a00T36bcR2AuzrD40W6ZuSrpjesZwE=; b=0i/COj8IVxJtQ11eGe0wldvdtYZUR4rPGTfu1Tpz9s0g2nusIkQtN7IMwqCZyrQiO6 JDKTb/PqogIoz3Wn0pyI1nKgOXXc6hxh39uuSdHr8e2nXW23nz6p6WioJFkKfSpTNQvg 6XSXm/OQHLHV6puZ6vVytsGxykOhYUUIxIUvfbAr/RSxB3Vq0HAwFBOqzRXNuhK59XzS fkE2r8bG7RMPT8rMBqeSEJK8eJj/ZNLscF28eY+l7MDwSpT3uH4dDIO967TGQxoI1j8t CiNS8QacHxr9Lhc4UqUTTeiTxMvBXPZrgKbGRJoLbKBT3CFEjIvB+Ihvt2LVmb5AGCZn 7ZJg== MIME-Version: 1.0 Received: by 10.50.189.200 with SMTP id gk8mr314774igc.65.1349420548734; Fri, 05 Oct 2012 00:02:28 -0700 (PDT) Received: by 10.42.64.139 with HTTP; Fri, 5 Oct 2012 00:02:28 -0700 (PDT) Date: Fri, 5 Oct 2012 12:32:28 +0530 Message-ID: Subject: Multiple Aggregate functions in map reduce program From: iwannaplay games To: user , user@hadoop.apache.org, hdfs-user Content-Type: multipart/alternative; boundary=14dae934085975c05804cb4a743d X-Virus-Checked: Checked by ClamAV on apache.org --14dae934085975c05804cb4a743d Content-Type: text/plain; charset=ISO-8859-1 Hi All, I have to get the count and sum of data for eg if my table is *employeename salary department* A 1000 testing B 2000 testing C 3000 development D 4000 testing E 1000 development F 5000 management I want result like Department TotalSalary count(employees) testing 7000 3 development 4000 2 management 5000 1 Please let me know whether it is possible to write a java map reduce for this.I tried this on hive.It takes time for big data.I heard map reduce java code will b faster.IS it true???Or i should go for pig programming?? Please guide.. Regards Prabhjot --14dae934085975c05804cb4a743d Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: base64 SGkgQWxsLDxicj48YnI+SSBoYXZlIHRvIGdldCB0aGUgY291bnQgYW5kIHN1bSBvZiBkYXRhPGJy PmZvciBlZyBpZiBteaAgdGFibGUgaXM8YnI+PGJyPjxicj48Yj5lbXBsb3llZW5hbWWgoCBzYWxh cnmgoCBkZXBhcnRtZW50PC9iPjxicj5BoKCgoKCgoKCgoKCgoKCgoKCgoKCgoCAxMDAwoKCgoCB0 ZXN0aW5nPGJyPkKgoKCgoKCgoKCgoKCgoKCg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