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 70F14200D53 for ; Tue, 21 Nov 2017 00:00:57 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 6F450160BF9; Mon, 20 Nov 2017 23:00:57 +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 AD527160BE1 for ; Tue, 21 Nov 2017 00:00:56 +0100 (CET) Received: (qmail 61659 invoked by uid 500); 20 Nov 2017 23:00:55 -0000 Mailing-List: contact dev-help@madlib.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@madlib.apache.org Delivered-To: mailing list dev@madlib.apache.org Received: (qmail 61648 invoked by uid 99); 20 Nov 2017 23:00:55 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 20 Nov 2017 23:00:55 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 76FC7DFF17; Mon, 20 Nov 2017 23:00:54 +0000 (UTC) From: iyerr3 To: dev@madlib.apache.org Reply-To: dev@madlib.apache.org References: In-Reply-To: Subject: [GitHub] madlib pull request #195: Feature: Add grouping support to HITS Content-Type: text/plain Message-Id: <20171120230054.76FC7DFF17@git1-us-west.apache.org> Date: Mon, 20 Nov 2017 23:00:54 +0000 (UTC) archived-at: Mon, 20 Nov 2017 23:00:57 -0000 Github user iyerr3 commented on a diff in the pull request: https://github.com/apache/madlib/pull/195#discussion_r152136163 --- Diff: src/ports/postgres/modules/utilities/utilities.py_in --- @@ -709,16 +709,35 @@ def _check_groups(tbl1, tbl2, grp_list): return ' AND '.join([" {tbl1}.{i} = {tbl2}.{i} ".format(**locals()) for i in grp_list]) - -def _grp_from_table(tbl, grp_list): - """ - Helper function for selecting grouping columns of a table +def get_filtered_cols_subquery_str(include_from_table, exclude_from_table, + filter_cols_list): + """ + This function returns a subquery string with columns in the filter_cols_list --- End diff -- I'm confused with this description string. My understanding is that the function doesn't really filter the columns - it filters the values for the columns i.e. it returns a subquery string that would filter values in exclude_from_table. If you're interested in filtering columns, then wouldn't querying the catalog and then doing a set difference be the better option? ---