code: @Then("^I check that result is:$")
      public void comparetable(DataTable dataTable) throws Exception {
  
          //from Cucumber Datatable, the pattern to verify
          List<String> tablePattern = new ArrayList<String>();
          tablePattern = dataTable.asList(String.class);
          //the result from select
          List<String> sqlTable = new ArrayList<String>();
  
          //the result is taken from previous step
          for (int i = 0; ThreadProperty.get("queryresponse" + i) != null; i++) {
              String ip_value = ThreadProperty.get("queryresponse" + i);
              sqlTable.add(i, ip_value);
          }
  
          for (int i = 0; ThreadProperty.get("queryresponse" + i) != null; i++) {
              ThreadProperty.remove("queryresponse" + i);
          }
  
          assertThat(tablePattern).as("response is not equal to the expected").isEqualTo(sqlTable);
      }
docs: /*
  @param tableName
  checks the result from select