SmartCSV.fx

Posted on November 29, 2015

A simple JavaFX application to load, save and edit a CSV file and provide a JSON configuration for columns to check the values in the columns.

At work I have the need to fix wrong CSV files from customers. It is hard to find the errors and fix them in a texteditor, even in a “normal” CSV editor. So I decided to write this simple JavaFX application.

JSON Configuration

 1 2 3 4 5 6 7 8 910111213141516171819202122
{ 
  "COLUMN NAME 1": { 
    "integer" : true, 
    "not empty" : true, 
    "maxlength" : 4, 
    "minlength" : 4 
  }, 
  "COLUMN NAME 2": { 
    "groovy" : "value.contains('a')? 'true' : 'no a inside'", 
    "alphanumeric" : true 
  }, 
  "COLUMN NAME 3": { 
    "date" : "yyyyMMdd", 
    "not empty" : true 
  }, 
  "COLUMN NAME 4": { 
    "date" : "yyyyMMdd" 
  }, 
  "COLUMN NAME 4": { 
    "regexp" : "[a-z]*" 
  } 
}

comments powered by Disqus