Added support for semicolon-separated value files #2759
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR Fixes #2753
Technical details:
Currently Mathesar allows importing DSV files with following delimiters:
,
\t
:
|
This pull request adds support for importing semicolon
;
separated values files as well.Additional references:
Mathesar uses clevercsv to detect the possible delimiter(s) of a file.
from the docs, I have noted the following definitions that might be relevant.
block_char (iterable) – Characters that are in the Punctuation Other category but that
should not be considered as escape character. If None, the default set is used, equal to:
"!", "?", '"', "'", ".", ",", ";", ":", "%", "*"
quote_chars (iterable) – Characters that should be considered quote characters. If it is
None, the following default set is used:
"'", '"', "~", "
"`delimiters (iterable) – List of delimiters to consider. If None, the
get_delimiters()
function is used to automatically detect the delimiterSemicolon is included in the set of block_chars, that means it's a potential candidate for being a delimiter.
Apart from that, I have tested the underlying logic of selecting delimiter for a given file on Google Colab and am attaching the same with this pull request to get this verified by you.
Checklist
Update index.md
).develop
branch of the repositoryvisible errors.
Developer Certificate of Origin
Developer Certificate of Origin