Skip to content
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

[BUG] <Deleting rows that contain the delmiter deletes everything> #554

Open
kreisligaspieler opened this issue Apr 19, 2024 · 0 comments
Open
Labels
bug Something isn't working

Comments

@kreisligaspieler
Copy link

kreisligaspieler commented Apr 19, 2024

Steps to reproduce

Imagine you have a delimiter , and an enclosing ". Trying to delete a row which contains a text like "A,B" causes the whole database to be empty. Might the code scan for the next delimiter (in this case ,) instead of first scanning for the next enclosing?
Example pipeline:
pipeline TestPipeline {
Extractor -> TextFileInterpreter->RangeSelector->CSVInterpreter->ColumnDeleter->RowDeleter->
TableInterpreter->Loader;
block Extractor oftype HttpExtractor {url: "https://geo.sv.rostock.de/download/opendata/museen/museen.csv";}
block TextFileInterpreter oftype TextFileInterpreter {encoding: "utf8";}
block RangeSelector oftype TextRangeSelector {lineFrom: 1;}
block CSVInterpreter oftype CSVInterpreter {enclosing: '"';delimiter: ",";}
block ColumnDeleter oftype ColumnDeleter {delete: [column I,];}
block TableInterpreter oftype TableInterpreter {
header: false;
columns: ["latitude" oftype decimal,"longitude" oftype decimal,"uuid" oftype text,"kreis_name" oftype text,"kreis_schluessel" oftype integer,"gemeindeverband_name" oftype text,"gemeindeverband_schluessel" oftype
integer,"gemeinde_schluessel" oftype integer,"gemeindeteil_name" oftype text,"gemeindeteil_schluessel" oftype integer,"strasse_name" oftype text,"strasse_schluessel" oftype integer,"hausnummer" oftype
integer,"hausnummer_zusatz" oftype text,"postleitzahl" oftype integer,"bezeichnung" oftype text,"traeger_bezeichnung" oftype text,"traeger_art" oftype text,"barrierefrei" oftype text,"oeffnungszeiten" oftype
text,"telefon_festnetz" oftype text,"telefon_mobil" oftype text,"email" oftype text,"website" oftype text];}
block Loader oftype SQLiteLoader {table: "test"; file: "test.sqlite";}
}

Description

  • Expected: Deleting column I
  • Actual: Generates empty table
@kreisligaspieler kreisligaspieler added the bug Something isn't working label Apr 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant