As Tommaso said, adding a field to the schema.xml gives you an automatic timestamp set at index time. The default schema.xml with Solr 3.5.0 has a commented example:
<field name="timestamp" type="date" indexed="true" stored="true" default="NOW" multiValued="false"/> -- Hector On Jan 20, 2012, at 8:15 AM, Tommaso Teofili wrote: > Hi Alex, > you can create a field in the schema.xml of type date or tdate called > (something like) idx_timestamp and set its default option to NOW then you > won't have to add any extra fields to the documents because it will be > automatically created when documents are indexed. > Hope it helps. > Tommaso > > 2012/1/20 ola nowak <ola.m.no...@gmail.com> > >> Hi, >> I want to be able to tell when the document was indexed, so I could >> re-index it if it has changed in the meantime. Is there an easy way to do >> this? Or I have to manualy put the date in the document and add a new field >> in schema? >> Thanks, >> Alex >>