Hi, I would index it in a field, you can use the database id and even add additional information so compose your own key and retrieve that (only) when you collect search results.
Wouter > Hi, > > what is the best way to retrieve our "real" ids (as they are in our > database) while searching? > > Right now we generate a file after indexing which contains all Lucene > docids and the matching id in our database. Our own Collector converts > the docids to our ids while collecting. This works as long as no > document is deleted and the index optimized after it. > > Is this a good solution or should we use Fields or DocValues for this? > What is the fastest solution? > > Regards, > > Sven Teichmann > --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org For additional commands, e-mail: java-user-h...@lucene.apache.org