-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow multiline filter expression with comments #457
Comments
Thanks for your request! It's already possible to get a (complex) filter expression from a file (use $ pica filter -f filter.txt "003@?" sample.dat The file content can contain whitespace-, tab- or newline-characters, but no comments. I'll implement the comment part soon! |
That's confusing. It it possible to set a default filter matching any field in this case? |
Actually, the filter expression from the CLI interface is overwritten by the content of the file, but it's not possible to omit the "dummy" cli argument. This is indeed confusing and I'll try to fix this issue soon. |
Current workaround is to use |
Just a short note about the workaround: I think this doesn't work with expressions containing values with an
|
The complexity of this issue seems low but I cannot tell. If so, I'd welcome it included in #505 or one of the next releases. |
Yesterday, I started with the implementation. Will be included in the upcoming release |
Sorry, this is more challenging as expected. I started working on this feature, but I must move this to |
I'd like to filter records by multiple conditions, and document the filter expression with comments. For this it would be useful to allow line breaks as whitespace in filter expressions and to allow comments (e.g. from
#
to the end of line). An example:Given this feature, filters can be collected in files:
The text was updated successfully, but these errors were encountered: