@Test
public void HttpGetFilterTest() {

    SqlParser parser = new SqlParser();
    Query q = null;
    Object o = new Object();
    JSONArray jsonArray = null;
    int num = 0, cou = 0;
    while (true) {
        o = HttpUtil.HttpGet(Settings.PRESTO_QUERY);
        jsonArray = JSON.parseArray(o.toString());
        String queryId = null;
        String query = null;
        for (int i = count; i < jsonArray.size(); i++) {
            System.out.println("Loop Times: " + num);
            JSONObject jsonObject = (JSONObject) jsonArray.get(i);
            if (jsonObject.size() == 8) {
                queryId = jsonObject.get("queryId").toString();
                query = jsonObject.get("query").toString();
                  System.out.println(queryId + "\t" + i + "\t" + query);
                // Parser
                try {
                    q = (Query) parser.createStatement(query);
                } catch (Exception e) {
                    ExceptionHandler.Instance().log(ExceptionType.ERROR, "query error", e);
                }
              System.out.println(q.toString());
                QuerySpecification queryBody = (QuerySpecification) q.getQueryBody();
                // get columns
                List<SelectItem> selectItemList = queryBody.getSelect().getSelectItems();
                for (SelectItem column : selectItemList) {
                    System.out.println(column.toString());
                }
                // tableName
                Table t = (Table) queryBody.getFrom().get();
                System.out.println(t.getName());
                if (t.getName().equals("text")) {
                    System.out.println("Text visit: " + cou++);
                }
            }
        }
        // update count
        count = jsonArray.size();
        num++;
        o = new Object();
    }
}