On Tue, 4 Jul 2017 at 22:39, Joe Ye <yuanzhou...@gmail.com> wrote: > Hi, > > I'm using Lucene core 6.6. > > I noticed an issue that DocValue update methods > (indexWriter.updateNumericDocValue > & indexWriter.updateBinaryDocValue) don't appear to throw exception or > return any error code if the document doesn't exist. Is this intentional? I > don't want to check the existence of the document before each docValue > update.
Given that they take Term or Query, that's what one would intuitively expect from such an API (it will match 0..n docs.) But the updates don't actually occur during the call, so there is no way for it to know how many updates will happen in advance anyway. (Otherwise it would be nice to know the number of docs it updated, like in JDBC.) TX