Skip to content

Ignore unknown columns in csvcut #1288

@dzhus

Description

@dzhus

Current behaviour:

dmitrydzhus@DD-MBP ~ % csvcut --version              
csvcut 2.1.0
dmitrydzhus@DD-MBP ~ % echo "A,B,C" | csvcut -c "A,X"
ColumnIdentifierError: Column 'X' is invalid. It is neither an integer nor a column name. Column names are: 'A', 'B', 'C'

What if there was a flag to simply ignore unknown columns in -c option of csvcut (similar to how -C works)?

E.g.

dmitrydzhus@DD-MBP ~ % echo "A,B,C" | csvcut --ignore-unknown -c "A,X"
A

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions