Mongodb的經常使用語句

模糊查詢  regex(".*?\\"+questionContent+".*")spa

        String questionContent = "需求";
        Query query = new Query();
        query.addCriteria(Criteria.where("demandName").regex(".*?\\"+questionContent+".*"));
        
        System.out.println(mongo.count(query, AdvTrusteeship.class));
相關文章
相關標籤/搜索