Question: I would like to create a generic method to create a specific dialog.

```
private void setDialog(String dialog,String title){
    try {
        // Load the fxml file and create a new stage for the popup
        FXMLLoader loader = new FXMLLoader(Main.class.getResource("/view/" + dialog + ".fxml"));
        AnchorPane page = (AnchorPane) loader.load();
        Stage dialogStage = new Stage();
        dialogStage.setTitle(title);
        dialogStage.initModality(Modality.WINDOW_MODAL);
        dialogStage.initOwner(Main.getPs());
        Scene scene = new Scene(page);
        dialogStage.setScene(scene);

     loader.getController().setDialogStage(dialogStage);

        // Show the dialog and wait until the user closes it
        dialogStage.showAndWait();

      } catch (IOException e) {
        // Exception gets thrown if the fxml file could not be loaded
        e.printStackTrace();
      }

}

```

But I get an error in this line 

```
loader.getController().setDialogStage(dialogStage)

```

exactly the mistake is this 

```
"The method setDialogStage(Stage) is undefined for the type Object"

```

how do I fix it? thank you.

I'm not very experienced. that says that

Answer: 
Basically you provide a String containing an SQL style where clause without the WHERE keyword like one of these examples.

* "name = 'Joe'"
* "age < 30"
* "name LIKE 'J%' AND age > 20"

I think this is the documentation you are looking for:
<https://backendless.com/docs/android/doc.html#search-with-the-where-clause>
Hi I finally got an answer. Thank you anyway. For those who has the same question... The syntax is below:

```
builder.setWhereClause("[COLUMN NAME] = " + "\'" + [VALUE YOU ARE SEARCHING FOR IN THE SPECIFIED COLUMN] + "\'");

```

Link: <https://backendless.com/docs/android/doc.html#search-with-the-where-clause>