Try this
index=main | head 1 | eval month_year=strftime(now(),"%c") | table month_year
http://docs.splunk.com/Documentation/Splunk/6.4.2/SearchReference/Commontimeformatvariables
Use following
| gentimes start=-1 | eval current_time=strftime(now(),"%B %d, %Y %H:%M") | table current_time
OR
| gentimes start=-1 | eval current_time=strftime(now(),"%+") | table current_time
Thanks @ somesoni2
Try this
index=main | head 1 | eval month_year=strftime(now(),"%c") | table month_year
http://docs.splunk.com/Documentation/Splunk/6.4.2/SearchReference/Commontimeformatvariables
Thanks @sundareshr