{"id":9683,"date":"2016-02-22T11:57:00","date_gmt":"2016-02-22T03:57:00","guid":{"rendered":"http:\/\/localhost\/help\/?page_id=9683"},"modified":"2024-08-15T10:31:33","modified_gmt":"2024-08-15T02:31:33","slug":"valueat_sampled","status":"publish","type":"page","link":"https:\/\/oihelp.corporate.ifs.com\/help\/p2-server\/calculations\/valueat_sampled\/","title":{"rendered":"ValueAt_Sampled()"},"content":{"rendered":"\n<h2><span id=\"Format\">Format<\/span><\/h2>\n<p class=\"intro-text\"><strong>ValueAt_Sampled(Expr,Time)<\/strong><\/p>\n<h2><span id=\"Returns\">Returns<\/span><\/h2>\n<p class=\"intro-text\">Returns the value of the expression at the specified time.<\/p>\n<h2><span id=\"Parameters\">Inputs<\/span><\/h2>\n<p class=\"intro-text\"><strong>Expr<\/strong>: The expression being evaluated.<br \/>\n Behaviour: Required<br \/>\n Dimension:\u00a0Collection<br \/>\n Valid\u00a0data types: Boolean, DateTime, Decimal, Integer, String, Duration, Error, Null<\/p>\n<p class=\"intro-text\"><strong>Time<\/strong>: The time at which the expression is to be evaluated. If this argument is an empty collection, the function will also return an empty collection rather than an error.<br \/>\n Behaviour:\u00a0Required<br \/>\n Dimension: Collection, SingleValue<br \/>\n Valid data types: DateTime, Decimal, Integer, String<\/p>\n<p class=\"left-bar\">Note: You can use the <a href=\"https:\/\/oihelp.corporate.ifs.com\/help\/p2-server\/calculations\/time\/\">Time<\/a>() function to use a valid DateTime argument.<\/p>\n<h2>Examples<\/h2>\n<p class=\"intro-text\">Expression:\u00a0<span class=\"code-fragment\">ValueAt_Sampled({tagname}, Time()\u00a0- 60)<\/span><br \/>\n Result: Value of tagname one minute (60 seconds) ago.<\/p>\n<p class=\"intro-text\">Expression: <span class=\"code-fragment\">ValueAt_Sampled({tagname1} + {tagname2}, Time() - 60)<\/span><br \/>\n Result: Value of sum of tagname1 and tagname2 one minute ago.<\/p>\n<p class=\"intro-text\">Expression: <span class=\"code-fragment\">ValueAt_Sampled({tagname}, ProductionDayStart(Time()))<\/span><br \/>\n Result: Value of tagname at the start of the production day.<\/p>\n<p class=\"intro-text\">\u00a0<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Use ValueAt_Sampled() to get the value of the expression at the specified time.<\/p>\n<p class=\"continue-reading-button\"> <a class=\"continue-reading-link\" href=\"https:\/\/oihelp.corporate.ifs.com\/help\/p2-server\/calculations\/valueat_sampled\/\">Read more<i class=\"crycon-right-dir\"><\/i><\/a><\/p>\n","protected":false},"author":1,"featured_media":9735,"parent":3650,"menu_order":241,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":"","_members_access_role":[],"_members_access_error":""},"categories":[9],"tags":[100,413,424],"class_list":["post-9683","page","type-page","status-publish","has-post-thumbnail","hentry","category-tech-ref","tag-calculations","tag-sampled","tag-valueat","Product-srv"],"_links":{"self":[{"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/pages\/9683","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=9683"}],"version-history":[{"count":1,"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/pages\/9683\/revisions"}],"predecessor-version":[{"id":46263,"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/pages\/9683\/revisions\/46263"}],"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\/9735"}],"wp:attachment":[{"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/media?parent=9683"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/categories?post=9683"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/oihelp.corporate.ifs.com\/help\/wp-json\/wp\/v2\/tags?post=9683"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}