title: Tableview Integer sorting bugged?
body: <p>I have a tableview and one of my columns consist of Integer values:</p>
  
  <ul>
  <li>1</li>
  <li>444
  -9</li>
  </ul>
  
  <p>If I sort on this column, I would expect 444 to be the "highest" number and therefor be the first row, but JavaFX believes 9 is higher?</p>
  
  <p>Any tips?</p>
  
  <p>MVCE:</p>
  
  <pre><code>public class TableViewTEST extends Application {
  
  private TableView table = new TableView();
  final ObservableList&lt;Person&gt; data = FXCollections.observableArrayList(
          new Person("1", "Smith", "jacob.smith@example.com"),
          new Person("9", "Johnson", "isabella.johnson@example.com"),
          new Person("444", "Williams", "ethan.williams@example.com")
  
  );
  
  @Override
  public void start(Stage stage) {
      table.getItems().addAll(data);
  
      Scene scene = new Scene(new Group());
  
      stage.setTitle(
              "Table View Sample");
      stage.setWidth(
              300);
      stage.setHeight(
              500);
  
      final Label label = new Label("Address Book");
  
      label.setFont(
              new Font("Arial", 20));
  
      TableColumn firstNameCol = new TableColumn("First");
      TableColumn lastNameCol = new TableColumn("Last Name");
      TableColumn emailCol = new TableColumn("Email");
  
      firstNameCol.setCellValueFactory(
              new PropertyValueFactory&lt;Person, String&gt;("firstName")
      );
      lastNameCol.setCellValueFactory(
              new PropertyValueFactory&lt;Person, String&gt;("lastName")
      );
      emailCol.setCellValueFactory(
              new PropertyValueFactory&lt;Person, String&gt;("email")
      );
  
      table.getColumns()
              .addAll(firstNameCol, lastNameCol, emailCol);
  
      final VBox vbox = new VBox();
  
      vbox.setSpacing(
              5);
      vbox.setPadding(
              new Insets(10, 0, 0, 10));
      vbox.getChildren()
              .addAll(label, table);
  
      ((Group) scene.getRoot()).getChildren().addAll(vbox);
  
      stage.setScene(scene);
  
      stage.show();
  }
  
  /**
   * @param args the command line arguments
   */
  public static void main(String[] args) {
      launch(args);
  }
  
  }
  </code></pre>
  
  <p><em>Edit</em></p>
  
  <p>Okay, I have found out the reason for this is because I use String in the model.. So the updated question is, how can you create a new sorting functionality on the table column so that it sorts as integer even though there's string in it? </p>