org.springframework.data.elasticsearch.annotations.Query Java Examples
The following examples show how to use
org.springframework.data.elasticsearch.annotations.Query.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: PostSearchRepository.java From expper with GNU General Public License v3.0 | 6 votes |
@Query("{" + " \"bool\": {" + " \"must\": [" + " {" + " \"term\": {" + " \"user.login\": \"?1\"" + " }" + " }, " + " {" + " \"bool\": {" + " \"should\": [" + " {" + " \"match\": {" + " \"title\": \"?0\"" + " }" + " }, " + " {" + " \"match\": {" + " \"tags.friendly_name\": \"?0\"" + " }" + " }" + " ]" + " }" + " }" + " ]" + " }" + " }") Page<Post> searchUserPosts(String query, String login, Pageable pageable);
Example #2
Source File: KisiRepository.java From spring-examples with GNU General Public License v3.0 | 5 votes |
@Query("{\"bool\": {\"must\": [{\"match\": {\"ad\": \"?0\"}}]}}") List<Kisi> getByCustomQuery(String search);
Example #3
Source File: FileSearchRepository.java From klask-io with GNU General Public License v3.0 | 5 votes |
@Query("{\"bool\" : {\"must\" : {\"bool\" : {\"should\" : [ {\"field\" : {\"version.raw\" : \"?\"}}, {\"field\" : {\"version.raw\" : \"?\"}} ]}}}}") Page<File> findByRawVersionIn(Collection<String> version, Pageable pageable);
Example #4
Source File: ArticleRepository.java From tutorials with MIT License | 5 votes |
@Query("{\"bool\": {\"must\": {\"match_all\": {}}, \"filter\": {\"term\": {\"tags\": \"?0\" }}}}") Page<Article> findByFilteredTagQuery(String tag, Pageable pageable);
Example #5
Source File: ArticleRepository.java From tutorials with MIT License | 5 votes |
@Query("{\"bool\": {\"must\": {\"match\": {\"authors.name\": \"?0\"}}, \"filter\": {\"term\": {\"tags\": \"?1\" }}}}") Page<Article> findByAuthorsNameAndFilteredTagQuery(String name, String tag, Pageable pageable);
Example #6
Source File: CalloutSaleCountRepository.java From youkefu with Apache License 2.0 | 4 votes |
@Transactional @Modifying @Query("delete from CalloutSaleCount where orgi = ?1") public void deleteByOrgi(String orgi);
Example #7
Source File: BookRepository.java From springBoot-study with Apache License 2.0 | 4 votes |
@Query("{\"bool\" : {\"must\" : {\"term\" : {\"message\" : \"?0\"}}}}") Page<Book> findByMessage(String message, Pageable pageable);
Example #8
Source File: FileSearchRepository.java From klask-io with GNU General Public License v3.0 | 4 votes |
@Query("{ \"bool\" : { \"must\" : { \"query\" : { \"term\" : { \"path\": \"?0\" } } } } }") File findFirstByPath(String path);
Example #9
Source File: FileSearchRepository.java From klask-io with GNU General Public License v3.0 | 4 votes |
@Query("{\"bool\" : {\"must\" : {\"field\" : {\"version.raw\" : \"?0\"}}}}") Page<File> findByRawVersion(String version, Pageable pageable);
Example #10
Source File: ArticleRepository.java From tutorials with MIT License | 4 votes |
@Query("{\"bool\": {\"must\": [{\"match\": {\"authors.name\": \"?0\"}}]}}") Page<Article> findByAuthorsNameUsingCustomQuery(String name, Pageable pageable);