Painless - how to access "@timestamp" field in script

You can do ctx._source['@timestamp'] = ctx._source['somedatefield']

2 Likes