Skip to content

Filtering by "contains" doesn't work with "_" #290

@davidhpark

Description

@davidhpark

Filtering for '_' using the 'contains' operator does not work:

In [50]: [q['amino_acid_change'] for q in query.filter(amino_acid_change__contains='_')]
Out[50]: []

However, filtering for '_' does work using the 'regexp' operator:

In [49]: [q['amino_acid_change'] for q in query.filter(amino_acid_change__regexp='.*_.*')]
Out[49]: 
[u'G504_P511del',
 ...
 u'P491_G492del']

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions