RE: how to search a tree node in lucene?

2017-03-05 Thread Uwe Schindler
nts can be used in both. Uwe - Uwe Schindler Achterdiek 19, D-28357 Bremen http://www.thetaphi.de eMail: u...@thetaphi.de > -Original Message- > From: Cristian Lorenzetto [mailto:cristian.lorenze...@gmail.com] > Sent: Sunday, March 5, 2017 6:13 PM > To: Lucene Users > Sub

Re: how to search a tree node in lucene?

2017-03-05 Thread Cristian Lorenzetto
it is lucene or solr? I m using lucene. 2017-03-05 18:06 GMT+01:00 Erick Erickson : > PathHeirarchyTokenizer? > > On Sat, Mar 4, 2017 at 5:00 PM, Cristian Lorenzetto > wrote: > > ah right ... facet ? it isnt? > > > > 2017-03-05 1:32 GMT+01:00 Cristian Lorenzetto < > cristian.lorenze...@gmail.co

Re: how to search a tree node in lucene?

2017-03-05 Thread Erick Erickson
PathHeirarchyTokenizer? On Sat, Mar 4, 2017 at 5:00 PM, Cristian Lorenzetto wrote: > ah right ... facet ? it isnt? > > 2017-03-05 1:32 GMT+01:00 Cristian Lorenzetto >: > >> Hi >> i might implement a performant solution for searching a tree node, parent >> of a node , children of a node. >> >> a

Re: how to search a tree node in lucene?

2017-03-04 Thread Cristian Lorenzetto
ah right ... facet ? it isnt? 2017-03-05 1:32 GMT+01:00 Cristian Lorenzetto : > Hi > i might implement a performant solution for searching a tree node, parent > of a node , children of a node. > > a simple idea is > > save the path to specific node > and searching prefix/suffix... > > > Is there

how to search a tree node in lucene?

2017-03-04 Thread Cristian Lorenzetto
Hi i might implement a performant solution for searching a tree node, parent of a node , children of a node. a simple idea is save the path to specific node and searching prefix/suffix... Is there a specific solution in the lucene libraries for doing it?

How to search keywords using apache lucene on apache tike indexed data.

2014-09-15 Thread MOHAMED MUSTHAFA
Hi Team, I indexed some html,doc and pdf files using apache tika. Now I want to search some keywords on this indexed data by apache lucene. Anyone to help me on this. -- = |* Thanks & Regards * | | * MOHAMED MUSTHAFA * | =

Re: How to search for terms containing negation

2014-03-18 Thread Jack Krupansky
Of course - you need to use the same analyzer for both indexing and query. So, just reindex your data with this new analyzer. -- Jack Krupansky -Original Message- From: Natalia Connolly Sent: Tuesday, March 18, 2014 10:37 AM To: java-user@lucene.apache.org Subject: Re: How to search

Re: How to search for terms containing negation

2014-03-18 Thread Natalia Connolly
I am afraid this did not work, Tri. Here's what I tried: List words = new ArrayList(); Boolean ignoreCase = true; CharArraySet emptyset = new CharArraySet(Version.LUCENE_47,words,ignoreCase); Analyzer analyzer = new StandardAnalyzer(Version.LUCENE_47,emptyset); Here's what happens: Searching fo

Re: How to search for terms containing negation

2014-03-17 Thread Tri Cao
StandardAnalyzer has a constructor that takes a stop word set, so I guess you can pass it an empty set:http://lucene.apache.org/core/4_6_1/analyzers-common/org/apache/lucene/analysis/standard/StandardAnalyzer.html#StandardAnalyzer(org.apache.lucene.util.Version, org.apache.lucene.analysis.util.Char

Re: How to search for terms containing negation

2014-03-17 Thread Natalia Connolly
Hi Tri, Thank you so much for your message! Yes, it looks like the negation terms have indeed been filtered out; when I query on "no" or "not", I get no results. I am just using StandardAnalyzer and the classic QueryParser: Analyzer analyzer = new StandardAnalyzer(Version.LUCENE_47); Que

Re: How to search for terms containing negation

2014-03-17 Thread Tri Cao
Natalia,First make sure that your analyzers (both index and query analyzers) do not filter out these as stop words. I think the standard StopFilter list has "no" and "not". You can try to see if you index have these terms by querying for "no" as a TermQuery. If there is not match for that query, th

How to search for terms containing negation

2014-03-17 Thread Natalia Connolly
Hi All, Is there any way I could construct a query that would not automatically exclude negation terms (such as "no", "not", etc)? For example, I need to find strings like "not happy", "no idea", "never available". I tried using a simple analyzer with combinations such as "not AND happy", an

Re: how to search a certain number of document without travelling all related documents

2013-03-14 Thread Trejkaz
On Tue, Mar 12, 2013 at 10:42 PM, Hu Jing wrote: > so my question is how to achieve a non-sort query method, this method can > get result constantly and don't travel all unnecessary doc. > > Does Lucene supply some strategies to implement this? If you want the result as soon as possible, just pa

Re: How to search multi-indice at the same time?

2011-07-23 Thread Israel Tsadok
http://lucene.apache.org/java/3_0_3/api/core/org/apache/lucene/index/MultiReader.html

How to search multi-indice at the same time?

2011-07-23 Thread dyzc2010
Hi, I was noting that some posts discussed searching multi-indice or folders simultaneously. But I can't find the posts any more. Please forward them to me if you happen to have one. Thanks

Re: how to search multiple fields

2011-05-25 Thread Ian Lea
> In the first link you presented, there is one comment that "Note that terms > which occur in short fields have a higher effect on the result ranking." > > What does "short fields" mean? This is a short sentence. This is a somewhat longer sentence that may get lower scores when matched by terms

Re: how to search multiple fields

2011-05-25 Thread Cheng Zhou
Hi lan, thanks. Still two questions. In the first link you presented, there is one comment that "Note that terms which occur in short fields have a higher effect on the result ranking." What does "short fields" mean? What are the differences between the impact of the short fields and that of the

Re: how to search multiple fields

2011-05-25 Thread Ian Lea
> Quite a few Lucene examples on lines shows how to insert multiple fields > into a Document and how to query the indexed file with certain fields and > queried text. I would like to know: > > 1.       How to do a cross-field search? http://wiki.apache.org/lucene-java/LuceneFAQ#How_can_I_search_ov

how to search multiple fields

2011-05-25 Thread zhoucheng2008
Hi, Quite a few Lucene examples on lines shows how to insert multiple fields into a Document and how to query the indexed file with certain fields and queried text. I would like to know: 1. How to do a cross-field search? 2. How to specify some key fields as well as some less i

Re: How to search by numbers

2010-04-19 Thread Erick Erickson
9 PM, Andy wrote: > > That works, and now that I re-test my original code, it also works. > > > Date: Mon, 19 Apr 2010 10:52:45 -0700 > > From: iori...@yahoo.com > > Subject: Re: How to search by numbers > > To: java-user@lucene.apache.org > > > > > >

RE: How to search by numbers

2010-04-19 Thread Andy
That works, and now that I re-test my original code, it also works. > Date: Mon, 19 Apr 2010 10:52:45 -0700 > From: iori...@yahoo.com > Subject: Re: How to search by numbers > To: java-user@lucene.apache.org > > > > Hi, I have indexed the following two fields: > >

Re: How to search by numbers

2010-04-19 Thread Ahmet Arslan
> Hi, I have indexed the following two fields: > org_id - NOT_ANALYZEDorg_name - ANALYZED > However when I try to search by org_id, for example, 12345, > I get no hits.  > I am using the StandardAnalyzer to index and search.  > > And I am using:  Query query = > queryParser.parse("org_id:12345")

How to search by numbers

2010-04-19 Thread Andy
Hi, I have indexed the following two fields: org_id - NOT_ANALYZEDorg_name - ANALYZED However when I try to search by org_id, for example, 12345, I get no hits. I am using the StandardAnalyzer to index and search. And I am using: Query query = queryParser.parse("org_id:12345"); Any ideas? Th

RE: How to search multiple fields using multiple search terms

2010-04-15 Thread Andy
I am just getting started with Lucene so I didnt know you could just use a regular query parser. That seems to work. Thanks > Date: Thu, 15 Apr 2010 19:32:50 -0400 > Subject: Re: How to search multiple fields using multiple search terms > From: erickerick...@gmail.com > T

Re: How to search multiple fields using multiple search terms

2010-04-15 Thread Erick Erickson
Why are you locked into using MultiFieldQueryParser? The simpler approach is just send something like +title:abc +desc:123 through the regular query parser HTH Erick On Thu, Apr 15, 2010 at 6:34 PM, Andy wrote: > > Hi, I am trying to use the MultiFieldQueryParser to search "title" and > "de

How to search multiple fields using multiple search terms

2010-04-15 Thread Andy
Hi, I am trying to use the MultiFieldQueryParser to search "title" and "desc" fields. However the Lucene API appears to only let me provide a single search term. Is it possible to use multiple search terms (one for each field)? For example, the SQL equivalent would be: select * from luce

Re: How to search "path"?

2009-07-30 Thread ohaya
Ian, I'll respond to this msg, re. searching "path". I made the change you suggested, to "Field.Index.ANALYZED", and that fixed the problem I was having with searching for components of the "path" field. Thanks! Jim Ian Lea wrote: > In contrast to your last question and reply, if you u

Re: How to search "path"?

2009-07-30 Thread Ian Lea
In contrast to your last question and reply, if you use doc.add(new Field("path", f.getPath(), Field.Store.YES, Field.Index.ANALYZED)); the path will get split into tokens which will include "myfile1" and you will be able to search for it. The key concept for both questions is analysis. Luce

How to search "path"?

2009-07-30 Thread ohaya
Hi, I am working with a modified version of the demo IndexFiles. In that code, when it builds the index, it has: doc.add(new Field("path", f.getPath(), Field.Store.YES, Field.Index.NOT_ANALYZED)); In Luke, I can see all the file paths in the "path" field. I am also using the demo lucenewe

Re: How to search special characters in LUcene

2009-04-27 Thread uday kumar maddigatla
> >> After this when i search for the >> >> >> http://www.nabble.com/file/p23170710/IndexFiles.java >> IndexFiles.java >> >> >> contains the danish elements .. Still it is not able to identify. >> >> >> >> >> >> P

Re: How to search special characters in LUcene

2009-04-24 Thread Erick Erickson
M, Uday Kumar Maddigatla > >> >> > wrote: > >> >> > > >> >> >> HI, > >> >> >> > >> >> >> > >> >> >> > >> >> >> I'm new to the lucene. I downloaded lucene 2.4

Re: How to search special characters in LUcene

2009-04-24 Thread uday kumar maddigatla
everal languages. >> >> > >> >> > Best >> >> > Erick >> >> > >> >> > On Tue, Apr 21, 2009 at 2:40 AM, Uday Kumar Maddigatla >> >> > wrote: >> >> > >> >> >> HI, >> >> >

Re: How to search special characters in LUcene

2009-04-23 Thread Erick Erickson
1, 2009 at 2:40 AM, Uday Kumar Maddigatla > >> > wrote: > >> > > >> >> HI, > >> >> > >> >> > >> >> > >> >> I'm new to the lucene. I downloaded lucene 2.4.1. > >> >> > >> >>

Re: How to search special characters in LUcene

2009-04-22 Thread uday kumar maddigatla
t; >> I'm new to the lucene. I downloaded lucene 2.4.1. >> >> >> >> >> >> >> >> I have one xml file which contains few special characters like 'å', >> 'ø,' >> >> °' >> >> etc.(these are D

Re: How to search special characters in LUcene

2009-04-22 Thread uday kumar maddigatla
t; >> I'm new to the lucene. I downloaded lucene 2.4.1. >> >> >> >> >> >> >> >> I have one xml file which contains few special characters like 'å', >> 'ø,' >> >> °' >> >> etc.(these are D

Re: How to search special characters in LUcene

2009-04-22 Thread Erick Erickson
; >> > >> How can I search these things. > >> > >> > >> > >> > >> > >> Uday Kumar Reddy Maddigatla > >> > >> Software Engineer(Progrator|gatetrade) > >> > >>

Re: How to search special characters in LUcene

2009-04-21 Thread uday kumar maddigatla
India(Operations) >> >> Mobile: + 91-9963000377 >> >> uday.maddiga...@ness.com <mailto:uday.maddiga...@ness.com> >> >> u...@mach.com <mailto:u...@mach.com> >> >> www.ness.com >> >> >> >> >> >> >

Re: How to search special characters in LUcene

2009-04-21 Thread Erick Erickson
Take a look at DutchAnalyzer. The problem you'll have is if you're indexing this document along with a bunch of documents from other languages. You could search the mail archive for extensive discussions of indexing/ searching documents from several languages. Best Erick On Tue, Apr 21, 2009 at

How to search special characters in LUcene

2009-04-20 Thread Uday Kumar Maddigatla
HI, I'm new to the lucene. I downloaded lucene 2.4.1. I have one xml file which contains few special characters like 'å', 'ø,' °' etc.(these are Danish language elements). How can I search these things. Uday Kumar Reddy Maddigatla Software Engineer(Progrator|gatetrade) MACH

Re: How to search a phrase using quotes in a query ???

2009-04-07 Thread Erick Erickson
Well, nothing jumps out at me, although I confess that I've not used MultiFieldQueryParser. So here's what I'd do. 1> drop back to a simpler way of doing things. Forget about MultiFieldQueryParser for instance. Get the really simple case working then build back up. I'd also drop back to a very bas

Re: How to search a phrase using quotes in a query ???

2009-04-07 Thread Ariel
Here is my code for indexing: [code] public static void main(String[] args) throws IOException { if(args.length==2){ String docsDirectory =args[0]; String indexFilepath = args[1]; int numIndexed = 0; IndexWriter writer; ArrayL

Re: How to search a phrase using quotes in a query ???

2009-04-06 Thread Erick Erickson
If you have luke, you should be able to submit your query and use the explain functionality to gain some insights into what the query actually looks like as well Best Erick On Mon, Apr 6, 2009 at 5:24 PM, Ariel wrote: > Well I have luke lucene, the index has been build fine. > The field whe

Re: How to search a phrase using quotes in a query ???

2009-04-06 Thread Ariel
Well I have luke lucene, the index has been build fine. The field where I am searching is the content field. I am using the same analyzer in query and indexing time: SnowBall English Analyzer. I am going to submit later the snippet code. Regards Ariel On Mon, Apr 6, 2009 at 4:37 PM, Erick Eric

Re: How to search a phrase using quotes in a query ???

2009-04-06 Thread Erick Erickson
We really need some more data. First, I *strongly* recommend you get a copy of Luke and examine your index to see what is *actually* there. Google "lucene luke". That often answers many questions. Second, query.toString is your friend. For instance, if the query you provided below is all that you'

How to search a phrase using quotes in a query ???

2009-04-06 Thread Ariel
Hi every body: Why when I make a query with this search query : "the fool of the hill" doesn't appear documents in the search results that contains the entire phrase "the fool of the hill" and it does exist documents that contain that phrase, I am using snowball analyzer for English ??? Could you

RE: How to search both Tokenized and Untokenized fields

2009-03-11 Thread Fang_Li
To: java-user@lucene.apache.org Subject: How to search both Tokenized and Untokenized fields Hi, I've been trying to find a way which allows executing a query that contains both Tokenized and Untokenized fields on Lucene's index, without having to parse the query. I've been ab

Re: How to search both Tokenized and Untokenized fields

2009-03-11 Thread Chris Hostetter
: Well, PerFieldAnalyzerWrapper is just a bunch of Analyzers,independent of : queries. See the API, but in general : PerFieldAnalyzerWrapper perf = new PerFieldAnalyzerWrapper("default", new : StandardAnalyzer()); : : perf.add("untokenized", new WhitespaceAnalyzer()); : perf.add("tokenized", new

Re: How to search both Tokenized and Untokenized fields

2009-03-11 Thread Erick Erickson
new QueryParser( DEFAULT_FIELD, analyzer); > >> Query query = queryParser.parse(queryString); > >> Hits hits = indexSearcher.search(query); > >> > >> This works fine for Tokenized fields but I'm not sure how to execute a > >> query > >>

Re: How to search both Tokenized and Untokenized fields

2009-03-10 Thread rokham
= new QueryParser( DEFAULT_FIELD, analyzer); >> Query query = queryParser.parse(queryString); >> Hits hits = indexSearcher.search(query); >> >> This works fine for Tokenized fields but I'm not sure how to execute a >> query >> ("queryString") w

Re: How to search both Tokenized and Untokenized fields

2009-03-09 Thread Erick Erickson
hich contains both tokenized and untokenized fields. > > Any suggestion is very much appreciated. > > Rokham > -- > View this message in context: > http://www.nabble.com/How-to-search-both-Tokenized-and-Untokenized-fields-tp22413438p22413438.html > Sent from the Lucene - Java Users

How to search both Tokenized and Untokenized fields

2009-03-09 Thread rokham
. Any suggestion is very much appreciated. Rokham -- View this message in context: http://www.nabble.com/How-to-search-both-Tokenized-and-Untokenized-fields-tp22413438p22413438.html Sent from the Lucene - Java Users mailing list archive at Nabble.com. --

Re: How to search on all fields with one query ?

2008-12-18 Thread Erick Erickson
A lot depends upon what you mean by "search across all fields". For single-term queries, that's pretty straight forward, but for, say, (a AND b) what does it mean to "search across all fields"? Should you get a hit if a appears only in field1 and b appears only in field 2? Or should you only get a

Re: TR: How to search on all fields with one query ?

2008-12-18 Thread Paul Libbrecht
I would do query expansion: - receive the query, parse it the way you want (e.g. use QueryParser) - then expand your query along the various fields If using different analyzers per field (e.g. soundex), you'll have to adjust things when coming into the term-query. paul Le 18-déc.-08 à 16:0

TR: How to search on all fields with one query ?

2008-12-18 Thread DELAVENNE Guillaume
Hi, I'm beginner on Lucene. I'm working on a Poc Lucene project at Generali France company. I have 40 fields (max ten words by field) in my index of about 6 millions documents. I need to search a word in all fields. Must I create a field "content" with all the informations of the others fields ?

Re: How to search documents taking in account the dates ???

2008-12-18 Thread Ariel
Thank you, it works very good. Regards Ariel On Thu, Dec 18, 2008 at 8:22 AM, Erick Erickson wrote: > Use the setSort that takes an array of Sort objects... > > On Thu, Dec 18, 2008 at 8:11 AM, Ariel wrote: > > > What I am doing is this: > > > >Sort sort = new Sort(); > >

Re: How to search documents taking in account the dates ???

2008-12-18 Thread Erick Erickson
Use the setSort that takes an array of Sort objects... On Thu, Dec 18, 2008 at 8:11 AM, Ariel wrote: > What I am doing is this: > >Sort sort = new Sort(); >sort.setSort("year", true); >hits = searcher.search(pquery,sort); > > > How I must put my code to sort

Re: How to search documents taking in account the dates ???

2008-12-18 Thread John Byrne
Hi, I think this should do it... SortField dateSortField = new SortField("year", false);//the second argument reverses the sort direction if set to true SortField scoreSortField= new SortField(null, SortField.SCORE, false); // value of null for field, since 'score' is not reall

Re: How to search documents taking in account the dates ???

2008-12-18 Thread Ariel
What I am doing is this: Sort sort = new Sort(); sort.setSort("year", true); hits = searcher.search(pquery,sort); How I must put my code to sort first by date an then by score ??? Greetings Ariel On Thu, Dec 18, 2008 at 4:48 AM, Ian Lea wrote: > Lucene let

Re: How to search documents taking in account the dates ???

2008-12-18 Thread Ian Lea
Lucene lets you sort by multiple fields, including score. See the javadocs for Sort and SortField, specifically SortField.SCORE. -- Ian. On Wed, Dec 17, 2008 at 8:15 PM, Ariel wrote: > Hi: > This solution have a problem. > the results are sorted bye the year criteria but I need that after sort

Re: How to search documents taking in account the dates ???

2008-12-17 Thread Ariel
Hi: This solution have a problem. the results are sorted bye the year criteria but I need that after sort by year criteria it sort by the scoring criteria two. How can I do this ??? I hope you can help me. Greetings Ariel On Wed, Nov 19, 2008 at 5:28 PM, Erick Erickson wrote: > Well, MultiSearch

Re: How to search for "-2" in field?

2008-12-12 Thread Darren Govoni
Hi Matt, Thanks for the thought. Yeah, I see it there in Luke, but the other gentleman's idea that maybe Luke is producing different than code might be a clue. It would be odd, if true, but nothing else works so I will see if that is it. Darren On Fri, 2008-12-12 at 08:03 -0500, Matthew Hall

Re: How to search for "-2" in field?

2008-12-12 Thread Greg Shackles
I admit I only read through this thread quickly so maybe I missed something, but it sounds like you're trying different Analyzers for searching, when what you really need is to use the right analyzer during indexing. Generally you want to use the same analyzer for both indexing and searching so tha

Re: How to search for "-2" in field?

2008-12-12 Thread Matthew Hall
Are you absolutely, 100% sure that the -2 token has actually made it into your index? As a VERY basic way to check this try something like this: import org.apache.lucene.index.IndexReader; import org.apache.lucene.index.TermEnum; public class IndexTerms { public static void main(Stri

Re: How to search for "-2" in field?

2008-12-12 Thread prabin meitei
one more thing, few times I have encountered that I get different results in Luke then in my actual code. Try in your code directly using standard analyzer and quoted query string. print your query to check if the query formed is correct (query is formed with quoted string). Can you tell what is

Re: How to search for "-2" in field?

2008-12-12 Thread Darren Govoni
Tried them all, with quotes, without. Doesn't work. At least in Luke it doesn't. On Fri, 2008-12-12 at 07:03 +0530, prabin meitei wrote: > whitespace analyzer will tokenize on white space irrespective of quotes. Use > standard analyzer or keyword analyzer. > Prabin meitei > toostep.com > > On Thu

Re: How to search for "-2" in field?

2008-12-11 Thread prabin meitei
whitespace analyzer will tokenize on white space irrespective of quotes. Use standard analyzer or keyword analyzer. Prabin meitei toostep.com On Thu, Dec 11, 2008 at 11:28 PM, Darren Govoni wrote: > I'm using Luke to find the right combination of quotes,\'s and > analyzers. > > No combination ca

Re: How to search for "-2" in field?

2008-12-11 Thread Darren Govoni
I'm using Luke to find the right combination of quotes,\'s and analyzers. No combination can produce a positive result for "-2 String" for the field 'type'. (any - ) type: 0 -2 Word analyzer: query -> rewritten = result default field is 'type'. WhitespaceAnalyzer: \"-2 ConfigurationFile\" ->

Re: How to search for "-2" in field?

2008-12-11 Thread prabin meitei
Hi, While constructing the query give the query string in quotes. eg: query = queryparser.parse("\"-2 word\""); Prabin meitei toostep.com On Thu, Dec 11, 2008 at 10:37 PM, Darren Govoni <[EMAIL PROTECTED]> wrote: > I'm hoping to do this with a simple query string, but not sure if its > possible

Re: How to search for "-2" in field?

2008-12-11 Thread Darren Govoni
I'm hoping to do this with a simple query string, but not sure if its possible. I'll try your suggestion though as a workaround. Thanks!! On Thu, 2008-12-11 at 16:48 +, Robert Young wrote: > You could do it with a TermQuery but I'm not quite sure if that's the answer > you're looking for. >

Re: How to search for "-2" in field?

2008-12-11 Thread Robert Young
You could do it with a TermQuery but I'm not quite sure if that's the answer you're looking for. Cheers Rob On Thu, Dec 11, 2008 at 3:59 PM, Darren Govoni <[EMAIL PROTECTED]> wrote: > Hi, > This might be a dumb question, but I have a simple field like this > > field: 0 -2 Word > > that is index

How to search for "-2" in field?

2008-12-11 Thread Darren Govoni
Hi, This might be a dumb question, but I have a simple field like this field: 0 -2 Word that is indexed,tokenized and stored. I've tried various ways in Lucene (using Luke) to search for "-2 Word" and none of them work, the query is re-written improperly. I escaped the -2 to "\-2 Word" and it s

Re: how to search for starts with multiple words in lucene

2008-11-28 Thread naveen.a
No Results >> 110_a:"library a*" No Results >> >> -------------- >> here, if i apply single word for starts with search, it is found, >> but

Re: how to search for starts with multiple words in lucene

2008-11-26 Thread AlexElba
if i apply single word for starts with search, it is found, > but if i add any space after the first word, it is not found > > so, how to apply the query to search for starts with multiple words > -- View this message in context: http://www.nabble.com/how-to-search-for-starts-with-

Re: how to search for starts with multiple words in lucene

2008-11-26 Thread Erick Erickson
" No Results > > -- > here, if i apply single word for starts with search, it is found, > but if i add any space after the first word, it is not found > > so, how to

how to search for starts with multiple words in lucene

2008-11-26 Thread naveen.a
No Results -- here, if i apply single word for starts with search, it is found, but if i add any space after the first word, it is not found so, how to apply the query to search for starts with multiple words -- View this message in context: http://www.nabble.com/how-to-search-for-starts-with-mult

Re: How to search documents taking in account the dates ???

2008-11-19 Thread Erick Erickson
Well, MultiSearcher is just a Searcher, so you have available all of the search methods on Searcher. One of which is: search public TopFieldDocs *search*(Query query, Filter filter, int n, Sort sort)

Re: How to search documents taking in account the dates ???

2008-11-19 Thread Ariel
Well, this is what I am doing: queryString="year:[2003 TO 2005]" [CODE] Query pquery = null; Hits hits = null; Analyzer analyzer = null; analyzer = new SnowballAnalyzer("English"); try { pquery = MultiFieldQueryParser.parse(new String[] {queryString, queryString}, new S

Re: How to search documents taking in account the dates ???

2008-11-19 Thread Ian Lea
Are you using one of the search methods that includes sorting? If not, then do. If you are, then you need to tell us exactly what you are doing and exactly what you reckon is going wrong. -- Ian. On Wed, Nov 19, 2008 at 6:23 PM, Ariel <[EMAIL PROTECTED]> wrote: > it is supposed lucene make a

Re: How to search documents taking in account the dates ???

2008-11-19 Thread Ariel
it is supposed lucene make a lexicocraphic sorting but this is not hapening, Could you tell me what I'm doing wrong ? I hope you can help me. Regards On Wed, Nov 19, 2008 at 11:56 AM, Ariel <[EMAIL PROTECTED]> wrote: > Thanks, that was very helpful, but I have a question when I make the > searche

Re: How to search documents taking in account the dates ???

2008-11-19 Thread Ariel
Thanks, that was very helpful, but I have a question when I make the searches it does not sort the results according to the range, for example: year: [2003 TO 2008] in the first page 2003 documents are showed, in the second 2005 documents, in the third page 2004 documents, I don't see any sort crit

Re: How to search documents taking in account the dates ???

2008-11-19 Thread Ian Lea
Hi - sounds like you need a range query. http://lucene.apache.org/java/2_3_2/queryparsersyntax.html#Range%20Searches -- Ian. On Wed, Nov 19, 2008 at 4:02 PM, Ariel <[EMAIL PROTECTED]> wrote: > Hi everybody: > > I need to make search with lucene 2.3.2, taking in account the dates, > previously

How to search documents taking in account the dates ???

2008-11-19 Thread Ariel
Hi everybody: I need to make search with lucene 2.3.2, taking in account the dates, previously when I build the index I create a date field where I stored the year in which the document was created, at the search moment I would like to retrieve documents that have been created before a Year or aft

Re: How to search in metadata? (filename, document title, cocument creator, ...)

2008-10-20 Thread Grant Ingersoll
-- View this message in context: http://www.nabble.com/How-to-search-in-metadata--%28filename%2C-document-title%2C-cocument-creator%2C-...%29-tp20069124p20078814.html Sent from the Lucene - Java Users mailing list archive at Nabble.com. -

RE: How to search in metadata? (filename, document title, cocument creator, ...)

2008-10-20 Thread mil84
message in context: http://www.nabble.com/How-to-search-in-metadata--%28filename%2C-document-title%2C-cocument-creator%2C-...%29-tp20069124p20078814.html Sent from the Lucene - Java Users mailing list archive at Nabble.com. - To

RE: How to search in metadata? (filename, document title, cocument creator, ...)

2008-10-20 Thread Steven A Rowe
On 10/20/2008 at 12:41 PM, mil84 wrote: > doc.add(new Field("Title", "hohoho", Field.Store.YES, Field.Index.TOKENIZED)); [...] > 3) Searching in title - it DON'T WORK (I try to find hohoho, and nothing). [...] > QueryParser parser = new QueryParser("title", new StandardAnalyzer()); Field names are

Re: How to search in metadata? (filename, document title, cocument creator, ...)

2008-10-20 Thread mil84
()); Query q = parser.parse(searchText); Hits hits = is.search(q); I simple can't understand, where I made mistake? It's simple code... -- View this message in context: http://www.nabble.com/How-to-search-in-metadata--%28filename%2C-document-title%2C-cocument-creato

Re: How to search in metadata? (filename, document title, cocument creator, ...)

2008-10-20 Thread Erick Erickson
t; writer.addDocument(doc); >> ... >> QueryParser parser = new QueryParser("contents", new StandardAnalyzer()); >> Query q = parser.parse(list.get(i)); >> Hits hits = is.search(createQuery(searchText)); >> >> Everything is ok, it searches document's con

Re: How to search in metadata? (filename, document title, cocument creator, ...)

2008-10-20 Thread Grant Ingersoll
iter.addDocument(doc); ... QueryParser parser = new QueryParser("contents", new StandardAnalyzer()); Query q = parser.parse(list.get(i)); Hits hits = is.search(createQuery(searchText)); Everything is ok, it searches document's contents. But how to search for example in filename

How to search in metadata? (filename, document title, cocument creator, ...)

2008-10-20 Thread mil84
ueryParser("contents", new StandardAnalyzer()); Query q = parser.parse(list.get(i)); Hits hits = is.search(createQuery(searchText)); Everything is ok, it searches document's contents. But how to search for example in filenames? I I add this: doc.add(new Field("filename

RE: How to search

2008-08-26 Thread Jiao, Jason (NSN - CN/Cheng Du)
y to look for those that match the pattern. Br. Jason Jiao >-Original Message- >From: ext Daniel Noll [mailto:[EMAIL PROTECTED] >Sent: Tuesday, August 26, 2008 10:50 AM >To: java-user@lucene.apache.org >Subject: Re: How to search > >Venkata Subbarayudu wrote: >

Re: How to search

2008-08-25 Thread Daniel Noll
Venkata Subbarayudu wrote: Hi Anshum Gupta, Thanks for your replay, but when I gone through querySyntax-Document for Lucene, I read that Lucene does not allow queries like "*findthis" i.e. I think it doesnot allow wildcards in the beginning of the query. It has supported this for some time

Re: How to search

2008-08-25 Thread Shalin Shekhar Mangar
On Mon, Aug 25, 2008 at 5:37 PM, Karl Wettin <[EMAIL PROTECTED]> wrote: > > Is this the specific use case, that you want to handle composite words as > in javaFieldAndClassNames? There is no native support for that in Lucene to > my knowledge, but it should not be too hard to implement a TokenStre

Re: How to search

2008-08-25 Thread Anshum
> > > >> > >> Hi All, > >> I am new to this Lucene, and I am using this for indexing and > >> searching. Is it possible to search substrings using this, for example > if > >> a > >> field holds the value "LuceneIndex" and

Re: How to search

2008-08-25 Thread Karl Wettin
25 aug 2008 kl. 13.54 skrev Venkata Subbarayudu: Hi All, I am new to this Lucene, and I am using this for indexing and searching. Is it possible to search substrings using this, for example if a field holds the value "LuceneIndex" and if a give the query as Index, I want to get this

Re: How to search

2008-08-25 Thread Venkata Subbarayudu
ndexing and >> searching. Is it possible to search substrings using this, for example if >> a >> field holds the value "LuceneIndex" and if a give the query as Index, I >> want >> to get this field also.. is there anyway for this. >> Thanks in Advan

Re: How to search

2008-08-25 Thread Anshum
> field holds the value "LuceneIndex" and if a give the query as Index, I > want > to get this field also.. is there anyway for this. > Thanks in Advance, > Venkata Subbarayudu. > -- > View this message in context: > http://www.nabble.com/How-to-search-tp191424

How to search

2008-08-25 Thread Venkata Subbarayudu
Thanks in Advance, Venkata Subbarayudu. -- View this message in context: http://www.nabble.com/How-to-search-tp19142469p19142469.html Sent from the Lucene - Java Users mailing list archive at Nabble.com. - To unsubscribe, e-ma

RE: How to search on the indexed content

2008-06-24 Thread Aamir.Yaseen
You can check this code for reference. http://lucene.apache.org/java/docs/demo4.html Regards, Aamir Yaseen -Original Message- From: Lucas F. A. Teixeira [mailto:[EMAIL PROTECTED] Sent: 24 June 2008 10:57 AM To: java-user@lucene.apache.org Subject: Re: How to search on the indexed

Re: How to search on the indexed content

2008-06-24 Thread Lucas F. A. Teixeira
http://lucene.apache.org/java/docs/queryparsersyntax.html []s, Lucas Frare A. Teixeira [EMAIL PROTECTED] Tel: +55 11 3660.1622 - R3018 yugana escreveu: Hi All, I have created an index file and indexing the content retrieved from a database. How can I search on thi

How to search on the indexed content

2008-06-24 Thread yugana
-to-search-on-the-indexed-content-tp18087133p18087133.html Sent from the Lucene - Java Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

  1   2   >