Question: Is there a Query or way in MySql to delete whitespaces in-between a String ?  

For Example - If I've a String **'Auto Robot Cars'** , the result should be 
**'AutoRobotCars'**   

I'm aware of TRIM function in MySql but it only deletes Leading & Trailing spaces not the WhiteSpaces in-between the String.

Answer: 
Use a `TextFormatter` with `UnaryOperator` and `StringConverter<Integer>` as shown below:

```
UnaryOperator<TextFormatter.Change> filter = change -> change.getControlNewText().matches("[0-3]?\\p{XDigit}{0,3}") ? change : null;

StringConverter<Integer> converter = new StringConverter<Integer>() {

    @Override
    public String toString(Integer object) {
        return object == null ? "" : Integer.toHexString(object);
    }

    @Override
    public Integer fromString(String string) {
        return string == null || string.isEmpty() ? null : Integer.parseInt(string, 16);
    }

};

TextFormatter<Integer> formatter = new TextFormatter<>(converter, null, filter);
textField.setTextFormatter(formatter);

```

The converted value is available via `TextFormatter.value` property. It only gets updated on pressing enter or the `TextField` loosing focus.
best way to do it is with regular expressions:

```
yourTextField.textProperty().addListener(new ChangeListener<String>() {
        @Override
        public void changed(ObservableValue<? extends String> observable, String oldValue,
                            String newValue) {
            if (!newValue.matches("^[0-9A-F]+$")) {
                yourTextField.setText(newValue.replaceAll("[^\\d]", ""));
            }
        }
    });

```

Is this what your are looking for?