Return-Path: X-Original-To: apmail-hbase-user-archive@www.apache.org Delivered-To: apmail-hbase-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 9C3861070C for ; Fri, 13 Sep 2013 16:09:27 +0000 (UTC) Received: (qmail 72551 invoked by uid 500); 13 Sep 2013 15:48:42 -0000 Delivered-To: apmail-hbase-user-archive@hbase.apache.org Received: (qmail 69805 invoked by uid 500); 13 Sep 2013 15:47:22 -0000 Mailing-List: contact user-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hbase.apache.org Delivered-To: mailing list user@hbase.apache.org Received: (qmail 62966 invoked by uid 99); 13 Sep 2013 14:39:17 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 13 Sep 2013 14:39:17 +0000 X-ASF-Spam-Status: No, hits=1.7 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of johnnyenglish739@gmail.com designates 209.85.215.46 as permitted sender) Received: from [209.85.215.46] (HELO mail-la0-f46.google.com) (209.85.215.46) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 13 Sep 2013 14:39:11 +0000 Received: by mail-la0-f46.google.com with SMTP id eh20so1089067lab.19 for ; Fri, 13 Sep 2013 07:38:50 -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=SfgSOLjgxW0iAgCyE0p8V0yKFldda5rDtwOBGVHfcUk=; b=lbT+oeq8dKNpF3w4RywfIU4FqWjfdQSxkJ/W77U/rcatt4j8ANU8uMwTUPRy95KUe/ a8YG7Ge0c8Ub/6KiESAzmWeyfYvdQd9ql9YvbUyagoVh3+Zdv1NpqI4rZTaFq7BW04f6 KoFajjnMEU/crI0vtNFCQEFiGpWpUCNa+o9mlmCxi8l71CCDFcrCGQjK8tlHQ/hjVqqf +37cHx6pyfife48Yl8Kxh2cdGqdsZjiPETEpTxrMMwXAB7LuVkpdMFgXBRzoM8lpGLUA qUx0CXYAHDDWi99s5BVQcKkKrW9o0oyJ4qpNbJPxntC4AGbH2D138bs+jEPSrxnbUa21 QK3w== MIME-Version: 1.0 X-Received: by 10.112.72.229 with SMTP id g5mr12316483lbv.10.1379083130663; Fri, 13 Sep 2013 07:38:50 -0700 (PDT) Received: by 10.114.181.39 with HTTP; Fri, 13 Sep 2013 07:38:50 -0700 (PDT) Date: Fri, 13 Sep 2013 16:38:50 +0200 Message-ID: Subject: Wrong HBase Sort Order with Pig From: John To: user@hbase.apache.org Content-Type: multipart/alternative; boundary=001a11c238e81e77eb04e644d032 X-Virus-Checked: Checked by ClamAV on apache.org --001a11c238e81e77eb04e644d032 Content-Type: text/plain; charset=ISO-8859-1 Hi, I already ask this on the pig mailing list. But because I'm not sure if it is a Pig or HBase issue, I will ask here too since the Pig Function is using a hbae scan operation. Here is my Questions: I have created a HBase Table in the hbase shell and added some data. In http://hbase.apache.org/book/dm.sort.html is written that the datasets are first sorted by the rowkey and then the column. So I tried something in the HBase Shell: http://pastebin.com/gLVAX0rJ Everything looks fine. I got the right order a -> c -> d like expected. Now I tried the same with Apache Pig in Java: http://pastebin.com/jdTpj4Fu I got this result: (key1,[c#val,d#val,a#val]) So, now the order is c -> d -> a. That seems a little odd to me, shouldn't it be the same like in HBase? It's important for me to get the right order because I transform the map afterwards into a bag and then join it with other tables. If both inputs are sorted I could use a merge join without sorting these two datasets. So does anyone know how it is possible to get the sorted map (or bag) of the columns? thanks --001a11c238e81e77eb04e644d032--