Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id B4F9E200CE3 for ; Sun, 13 Aug 2017 20:09:27 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id A986B163B6B; Sun, 13 Aug 2017 18:09:27 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id EF304163B18 for ; Sun, 13 Aug 2017 20:09:26 +0200 (CEST) Received: (qmail 75617 invoked by uid 500); 13 Aug 2017 18:09:25 -0000 Mailing-List: contact user-help@flink.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list user@flink.apache.org Received: (qmail 75606 invoked by uid 99); 13 Aug 2017 18:09:25 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 13 Aug 2017 18:09:25 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id DE1F21A0AF7 for ; Sun, 13 Aug 2017 18:09:23 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.389 X-Spam-Level: ** X-Spam-Status: No, score=2.389 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001, T_FILL_THIS_FORM_SHORT=0.01] autolearn=disabled Authentication-Results: spamd2-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id mnfEVNcrtT-E for ; Sun, 13 Aug 2017 18:09:21 +0000 (UTC) Received: from mail-yw0-f179.google.com (mail-yw0-f179.google.com [209.85.161.179]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id 458A45F4A9 for ; Sun, 13 Aug 2017 18:09:21 +0000 (UTC) Received: by mail-yw0-f179.google.com with SMTP id p68so44908548ywg.0 for ; Sun, 13 Aug 2017 11:09:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=S/yIk8pyQfdulmefcnBVmt6cwEeOssWqwm6g9sK1tbs=; b=LhZ5vk9ZK+rABexY4Kz1ehePEii45PuTXGXnOYiO7980KZaZaNexhF+0Frm9MHESJy giD5ATa7dDNa/OoNR3GBkwiHhqVl8PRT81VAyb0R6SagsO3c1WD8CHYA40lyrUpBwULR Q6f+KpqkX6SmQUei1KlNwJYnS/qwkUjtgHYdHF+yF6kGG0KYpqZWFiODIEzHwjgmPoIf 22rOt8P1MQJcAldkQtmsmTZJuxb2yuSXNRROg9nZpp8SN7WvBLvfpbMph49iOAIdx99w gdnfktFdx6qUnK8IG4qYjAJhxy+4FUVYty3oiZIpn790PmwjR15ul/3RaWYXX5qRjzI2 dMTg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=S/yIk8pyQfdulmefcnBVmt6cwEeOssWqwm6g9sK1tbs=; b=GbBzlmoD254FZsG63sxAyrQK6biE5m+MICkxXgfTAvluqN8tIgQxhD7IOP0l0gzode v1P7BlH28cdmLpcuZwjF7kfJqgcyONG2gZSXlQwJV9c8CU8K5biEdH2EfxEW4NEadz+i t52NCiIfzh2Cq6CEJc6/53sM80AMBOoEK2DrLO4C9O0K4kozZpaREaIvyzM3T3WzvE7n 2eTgkdQW/BJ065mkekh32oQH/u9UfY5e6S77p0dY8BnWOnbM1If2UqR5GdwKGK7L6qyI XSr6+uGdFzL1WlPAPw7kXhDaqxdGJI30tUNB+Usc/njgjGJ/bxkehFba6pNF9Q/kZwHr 239w== X-Gm-Message-State: AHYfb5iUrKlYCFPAxW4VXGnpGV/PHdpnm76h+P0YoLeJXJqWrGERhp1L Utnn1ExEc0m2EONZMAZU5hd8nxgq+w== X-Received: by 10.37.173.28 with SMTP id y28mr17266331ybi.78.1502647754992; Sun, 13 Aug 2017 11:09:14 -0700 (PDT) MIME-Version: 1.0 Received: by 10.37.176.5 with HTTP; Sun, 13 Aug 2017 11:09:14 -0700 (PDT) From: Basanth Gowda Date: Sun, 13 Aug 2017 14:09:14 -0400 Message-ID: Subject: Aggregation by key hierarchy To: user@flink.apache.org Content-Type: multipart/alternative; boundary="f403045da182a8b4e00556a6717a" archived-at: Sun, 13 Aug 2017 18:09:27 -0000 --f403045da182a8b4e00556a6717a Content-Type: text/plain; charset="UTF-8" Hi, I want to aggregate hits by Country, State, City. I would these as tags in my sample data. How would I do aggregation at different levels ? Input data would be single record Should I do flatMap transformation first and create 3 records from 1 input record, or is there a better way to do it ? thank you, basanth --f403045da182a8b4e00556a6717a Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi,
I want to aggregate hits by Country, State, City. = I would these as tags in my sample data.

How would= I do aggregation at different levels ? Input data would be single record

Should I do flatMap transformation first and create= 3 records from 1 input record, or is there a better way to do it ?

thank you,
basanth=C2=A0
--f403045da182a8b4e00556a6717a--