cancel
Showing results for 
Search instead for 
Did you mean: 

Lucene Query Issues

stockbuyer
Champ in-the-making
Champ in-the-making
Hi all,

I want to search the file which the filename is "PDF", when I use the following query to search the repository, it will return all files which the name contains "PDF", is it possible to search the file with exact match mode?

Query query = new Query(Constants.QUERY_LANG_LUCENE, "@cm\\:name:\"PDF\"");

Best Regards,
Peter
2 REPLIES 2

jpotts
World-Class Innovator
World-Class Innovator
Did you know you could search specifically by mimetype? Then it doesn't matter how the files are named:
@cm\:content.mimetype:"application/pdf"

Jeff

stockbuyer
Champ in-the-making
Champ in-the-making
Did you know you could search specifically by mimetype? Then it doesn't matter how the files are named:
@cm\:content.mimetype:"application/pdf"

Jeff

Hi Jeff,

I know that I can search the repository by mimetype, the word "PDF" is an example. I just want to know is it possible to search a string with exact match mode.

Best Regards,
Peter