Created 10-17-2017 07:56 PM
Hi,
Thanks
My directory in HDFS is yyyy/mm/dd/hh/mm/ss is there any way I can restrict it till month. example yyyy/mm
Thanks
Dheeru
Created 10-17-2017 08:08 PM
yeah you can change the format to below
${now():format("yyyyMM")}
will gives you only year and month.
In addition you make use any combination in EL in date manupulations with now():-
yyyy //gives only the year MM //month dd //date HH//hours mm // minutes from time (MM are for month) ss // seconds SSS //milliseconds
Examples:-
1.year with month
${now():format("yyyy-MM")}
output:-
2017-10
2.Hour with minute
${now():format("HH:mm")}
Output:-
16:17
3.year with minutes
${now():format("yyyymm")}
output:-
201713 //13 because minute from current time stamp
4.year with date
${now():format("yyyydd")}
output:-
201717 //year with today's date
Created 10-17-2017 08:08 PM
yeah you can change the format to below
${now():format("yyyyMM")}
will gives you only year and month.
In addition you make use any combination in EL in date manupulations with now():-
yyyy //gives only the year MM //month dd //date HH//hours mm // minutes from time (MM are for month) ss // seconds SSS //milliseconds
Examples:-
1.year with month
${now():format("yyyy-MM")}
output:-
2017-10
2.Hour with minute
${now():format("HH:mm")}
Output:-
16:17
3.year with minutes
${now():format("yyyymm")}
output:-
201713 //13 because minute from current time stamp
4.year with date
${now():format("yyyydd")}
output:-
201717 //year with today's date
Created 10-17-2017 08:24 PM
@Shu I was just reading the docs found out ${now():format('yyyy')}. Thanks for the quick response. Much appreciated.
Dheeru