{"id":9857,"date":"2016-02-22T15:52:41","date_gmt":"2016-02-22T07:52:41","guid":{"rendered":"http:\/\/localhost\/help\/?page_id=9857"},"modified":"2024-08-15T10:31:32","modified_gmt":"2024-08-15T02:31:32","slug":"time","status":"publish","type":"page","link":"https:\/\/oihelp.corporate.ifs.com\/help\/p2-server\/calculations\/time\/","title":{"rendered":"Time()"},"content":{"rendered":"\n<h2><span id=\"Format\">Format<\/span><\/h2>\n<p class=\"intro-text\"><strong>Time()<\/strong><\/p>\n<h2><span id=\"Returns\">Returns<\/span><\/h2>\n<p class=\"intro-text\">Returns the timestamp of each sample point, expressed in seconds since the 1st of January 1970, UTC.<\/p>\n<h2>When to Use<\/h2>\n<p class=\"intro-text\">This can be useful when you call date-time functions and you want the date arithmetic to be done at that time.<\/p>\n<p class=\"intro-text\">You can use this function as a parameter for any\u00a0function that accepts a DateTime parameter.<\/p>\n<p class=\"intro-text\">E.g.\u00a0If your start time is 9am and your end time is 11am and you have a 30 minute sample interval, then it will return:<\/p>\n<table>\n<tbody>\n<tr>\n<td width=\"208\"><strong>Timestamp<\/strong><\/td>\n<td width=\"208\"><strong>Value<\/strong><\/td>\n<td width=\"208\"><strong>Confidence<\/strong><\/td>\n<\/tr>\n<tr>\n<td width=\"208\">9:00<\/td>\n<td width=\"208\">9:00<\/td>\n<td width=\"208\">100<\/td>\n<\/tr>\n<tr>\n<td width=\"208\">9:30<\/td>\n<td width=\"208\">9:30<\/td>\n<td width=\"208\">100<\/td>\n<\/tr>\n<tr>\n<td width=\"208\">10:00<\/td>\n<td width=\"208\">10:00<\/td>\n<td width=\"208\">100<\/td>\n<\/tr>\n<tr>\n<td width=\"208\">10:30<\/td>\n<td width=\"208\">10:30<\/td>\n<td width=\"208\">100<\/td>\n<\/tr>\n<tr>\n<td width=\"208\">11:00<\/td>\n<td width=\"208\">11:00<\/td>\n<td width=\"208\">100<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p class=\"intro-text\">You can then use these as input values to other functions, such as the sampled ones.<\/p>\n<h2><span id=\"Examples\">Examples<\/span><\/h2>\n<p class=\"intro-text\">Expression: <span class=\"code-fragment\">CalendarDayStart(Time())<\/span><br \/>\n Result: Returns the start of the day in the configured calendar time zone.<\/p>\n<p class=\"intro-text\">Expression: <span class=\"code-fragment\">CalendarDayStart(Time(), ProductionTimeZone())<\/span><br \/>\n Result: Returns the start of the day in the configured production time zone.<\/p>\n<p class=\"intro-text\">Expression: <span class=\"code-fragment\">CalendarDayStart(Time(), \"Australia\/Perth\")<\/span><br \/>\n Result: Returns the start of the day in Perth\u2019s time zone.<\/p>\n<p class=\"intro-text\">\u00a0<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Use Time() to get the timestamp of each sample point.<\/p>\n<p class=\"continue-reading-button\"> <a class=\"continue-reading-link\" href=\"https:\/\/oihelp.corporate.ifs.com\/help\/p2-server\/calculations\/time\/\">Read more<i class=\"crycon-right-dir\"><\/i><\/a><\/p>\n","protected":false},"author":1,"featured_media":9858,"parent":3650,"menu_order":216,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":"","_members_access_role":[],"_members_access_error":""},"categories":[9],"tags":[100,154],"class_list":["post-9857","page","type-page","status-publish","has-post-thumbnail","hentry","category-tech-ref","tag-calculations","tag-time","Product-srv"],"_links":{"self":[{"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/pages\/9857","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/comments?post=9857"}],"version-history":[{"count":1,"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/pages\/9857\/revisions"}],"predecessor-version":[{"id":46253,"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/pages\/9857\/revisions\/46253"}],"up":[{"embeddable":true,"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/pages\/3650"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/media\/9858"}],"wp:attachment":[{"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/media?parent=9857"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/categories?post=9857"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/tags?post=9857"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}