Uploaded image for project: 'Apache IoTDB'
  1. Apache IoTDB
  2. IOTDB-1234

ImportCSV tool cannot parse empty string values

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 0.12.0
    • None

    Description

      IoTDB ImportCSV tool failed to process empty string values.
      ImportCSV and ExportCSV tools are under cli/target/iotdb-cli-{version}/tools

      To reproduce:
      1. Write data into IoTDB with null value.
      ```
      CREATE TIMESERIES root.ln.wf01.wt01.status WITH DATATYPE=BOOLEAN, ENCODING=PLAIN
      CREATE TIMESERIES root.ln.wf01.wt01.temperature WITH DATATYPE=FLOAT, ENCODING=RLE
      INSERT INTO root.ln.wf01.wt01(timestamp,status) values(100,true);
      INSERT INTO root.ln.wf01.wt01(timestamp,status,temperature) values(200,false,20.71)
      INSERT INTO root.ln.wf01.wt01(timestamp,status,temperature) values(600,false,71.12)
      ```

      2. Write a SQL script called abc.sql including one line command.
      ```
      select * from root.ln.wf01.wt01
      ```

      3. Use exportCSV tool to generate a .csv file with abc.sql.
      ./export-csv.sh -h 127.0.0.1 -p 6667 -u root -pw root -td ./ -s abc.sql

      4. Use importCSV tool to write this "dump0.csv" back to IoTDB.
      /import-csv.sh -h 127.0.0.1 -p 6667 -u root -pw root -f dump0.csv

      And it failed with error message.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              kofshao Wei Shao
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: