First of all let's create two variable containing a date and a time value:
>> a: now/date
== 24-May-2013
>> b: now/time
== 12:31:46
Well you can call each single value (day, minutes, etc.) in many ways:
>> a/day
== 21
>> a/1
== 21
>> a/month
== 5
>> a/year
== 2013
>> b/hour
== 12
>> b/minute
== 31
>> b/second
== 46.0
As you can see, you can ask for hour or minute in a very human friendly way. However you can use also position number.
You can perform this also in a complete date:
>> c: now
== 24-May-2013/12:39:06+2:00
>> c/date
== 24-May-2013
>> c/time
== 12:39:06
>> c/time/hour
== 12
>> c/date/year
== 2013
Now you know all ways to call a single part of a date! variable
No comments:
Post a Comment