madlib-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kaknikhil <...@git.apache.org>
Subject [GitHub] madlib pull request #282: Utilites: Add CTAS while dropping some columns
Date Thu, 28 Jun 2018 23:48:41 GMT
Github user kaknikhil commented on a diff in the pull request:

    https://github.com/apache/madlib/pull/282#discussion_r199006902
  
    --- Diff: src/ports/postgres/modules/utilities/utilities.py_in ---
    @@ -853,6 +857,34 @@ def validate_module_input_params(source_table, output_table, independent_varname
                                                source_table=source_table))
     # ------------------------------------------------------------------------
     
    +
    +def create_table_drop_cols(source_table, out_table,
    +                           cols_to_drop, **kwargs):
    +    """ Create copy of table while dropping some of the columns
    +    Args:
    +        @param source_table str. Name of the source table
    +        @param out_table str. Name of the output table
    +        @param cols_to_drop str. Comma-separated list of columns to drop
    +    """
    +    input_tbl_valid(source_table, 'Utilities')
    +    output_tbl_valid(out_table, 'Utilities')
    +
    --- End diff --
    
    should we error out if the requested column to drop is not a valid column in the table?
If not , then we should add a note about this in the user docs


---

Mime
View raw message