{"id":8835,"date":"2018-02-09T11:08:06","date_gmt":"2018-02-09T17:08:06","guid":{"rendered":"https:\/\/www.mrc-productivity.com\/legacy\/?page_id=8835"},"modified":"2020-03-02T15:55:33","modified_gmt":"2020-03-02T21:55:33","slug":"period-analysis","status":"publish","type":"page","link":"https:\/\/www.mrc-productivity.com\/legacy\/reports\/period-analysis","title":{"rendered":"Date Period Analysis"},"content":{"rendered":"<h1>Date Period Analysis<\/h1>\n<p>The period analysis tool allows end-users the ability to quickly choose from a list of pre-set date values to filter reports. Common values include dates such as &#39;today&#39;, &#39;yesterday&#39;, and &#39;this week&#39; to more complicated date ranges such as &#39;last month to date&#39; and &#39;last fiscal quarter&#39;. Additionally, end-users are given the ability to easily compare two different date ranges against each other.<\/p>\n<p><iframe loading=\"lazy\" width=\"560\" height=\"315\" src=\"https:\/\/www.youtube.com\/embed\/e0X6H8N1FaY\" frameborder=\"0\" allow=\"autoplay; encrypted-media\" allowfullscreen=\"\"><\/iframe><\/p>\n<p>Jump to:<\/p>\n<p><a href=\"#compare\">Comparing Dates<\/a><br \/>\n<a href=\"#webparms\">Web Parameters<\/a><br \/>\n<a href=\"#notes\">Additional Notes<\/a><\/p>\n<h2>Getting Started<\/h2>\n<p>When a true date field is selected as a record selection, specific date related relationships become available. To allow the end-user to perform runtime period analysis, select &#39;Period Analysis&#39; as the relation.<\/p>\n<p><img decoding=\"async\" alt=\"relationship\" src=\"\/legacy\/images\/pop\/relationship.png\"><\/p>\n<p>At runtime, the end-user is given full command of filtering and\/or comparing dates.<\/p>\n<p><img decoding=\"async\" alt=\"runtime1\" src=\"\/legacy\/images\/pop\/runtime1.png\"><\/p>\n<p>The most basic use of this tool is to simply filter the data based on a common date. Aside from the manual date selection of &#39;Equal to&#39; or &#39;In the range&#39;, the relation dropdown has many built-in options for common date values.<\/p>\n<p><img decoding=\"async\" style=\"margin: auto;\" alt=\"relation dropdown\" src=\"\/legacy\/images\/pop\/relationDropdown.png\"><\/p>\n<h2 id=\"compare\">Comparing Dates<\/h2>\n<p>Comparison options include Prior Period, Prior Year, and Custom Range (a fourth option called Prior Year Adjusted can be added by following these instructions <a href=\"https:\/\/www.mrc-productivity.com\/techblog\/?p=10655\" target=\"_blank\"> here<\/a>). If a user has selected data from this month, and chooses to compare to the previous period, all numeric fields will display two columns. One column contains the data for this month (current period) and the other column will hold data for last month (prior period). The same can be expected for previous year and a custom range.<\/p>\n<p><img decoding=\"async\" style=\"margin: auto;\" alt=\"runtime columns\" src=\"\/legacy\/images\/pop\/runtime2.png\"><\/p>\n<h2 id=\"webparms\">URL Web Parameters<\/h2>\n<p>Like all other report prompt options, the period analysis tool can be passed to the report via URL parameters. This becomes especially relevant when using reports in the messaging and scheduled task utility as well as using reports in dashboard.<\/p>\n<ul>\n<li><strong>compareOn: <\/strong> Set the option to compare against.\n<p style=\"padding-left: 40px;\"><em>Available values: <\/em>period, custom, year,<a href=\"https:\/\/www.mrc-productivity.com\/techblog\/?p=10655\" target=\"_blank\"> prior-adjusted<\/a><\/p>\n<\/li>\n<li><strong>rls_RXXX: <\/strong> Set the date relationship value.\n<p style=\"padding-left: 40px;\"><em>Available values: <\/em><br \/>\nEQ: equal to<br \/>\nRG: in the range<br \/>\nGE: Greater than or equal to<br \/>\nGT: Greater than<br \/>\nLE: Less than or equal to<br \/>\nLT: Less than<br \/>\nD1: is today<br \/>\nD2: is yesterday<br \/>\nW1: is this week<br \/>\nW2: is this week to date<br \/>\nW3: is last week<br \/>\nW4: is last week-to-date<br \/>\nM1: is this month<br \/>\nM2: is this month-to-date<br \/>\nM3: is last month<br \/>\nM4: is last month-to-date<br \/>\nQ1: is this (fiscal) quarter<br \/>\nQ5: is this quarter<br \/>\nQ2: is this (fiscal) quarter-to-date<br \/>\nQ6: is this quarter-to-date<br \/>\nQ3: is last (fiscal) quarter<br \/>\nQ7: is last quarter<br \/>\nQ4: is last (fiscal) quarter-to-date<br \/>\nQ8: is last quarter-to-date<br \/>\nY1: is this (fiscal) year<br \/>\nZ1: is this year<br \/>\nY2: is this (fiscal) year-to-date<br \/>\nZ2: is this year-to-date<br \/>\nY3: is last (fiscal) year<br \/>\nZ3: is last year<br \/>\nY4: is last (fiscal) year-to-date<br \/>\nZ4: is last year-to-date<\/li>\n<li><strong>RXXX: <\/strong> Set the manual date value if the relationship above does not set the date already.\n<p style=\"padding-left: 40px;\"><em>Available values: <\/em> Any valid date value. <strong>Note: <\/strong> If the relationship is set to RG, two RXXX values will be needed.<\/p>\n<\/li>\n<li><strong>compVal1\/compVal2: <\/strong> Applicable and required only if using a custom comparison. Set the custom date range values for the start date (compVal1) and end date (compVal2).\n<p style=\"padding-left: 40px;\"><em>Available values: <\/em> Any valid date values.<\/p>\n<\/li>\n<li><strong>Examples: <\/strong>\n<p style=\"padding-left: 40px; margin-bottom: 0px;\">compareOn=period&amp;rls_R001=D1<\/p>\n<p style=\"padding-left: 80px;\"><em>Display data from today compared to yesterday.<\/em><\/p>\n<p style=\"padding-left: 40px; margin-bottom: 0px;\">compareOn=period&amp;rls_R001=RG&amp;R001=01\/15\/2018&amp;R001=01\/18\/2018<\/p>\n<p style=\"padding-left: 80px;\"><em>Display data from a date range of 01\/15\/2018 &#8211; 01\/18\/2018 compared to 01\/11\/2018 &#8211; 01\/14\/2018.<\/em><\/p>\n<p style=\"padding-left: 40px; margin-bottom: 0px;\">compareOn=year&amp;rls_R001=Y1<\/p>\n<p style=\"padding-left: 80px;\"><em>Display data from this year compared to last year.<\/em><\/p>\n<p style=\"padding-left: 40px; margin-bottom: 0px;\">compareOn=year&amp;rls_R001=RG&amp;R001=01\/15\/2018&amp;R001=01\/18\/2018<\/p>\n<p style=\"padding-left: 80px;\"><em>Display data from a date range of 01\/15\/2018 &#8211; 01\/18\/2018 compared to 01\/15\/2017 &#8211; 01\/18\/2017.<\/em><\/p>\n<p style=\"padding-left: 40px; margin-bottom: 0px;\">compareOn=custom&amp;rls_R001=M2&amp;compVal1=01\/20\/2018&amp;compVal2=01\/26\/2018<\/p>\n<p style=\"padding-left: 80px;\"><em>Display data from this month-to-date compared to 01\/20\/2018 &#8211; 01\/26\/2018.<\/em><\/p>\n<\/li>\n<h2 id=\"notes\">Additional Notes<\/h2>\n<ul>\n<li class=\"padleft\">The heading text representing the (Current) and (Prior) columns may be changed from Admin Menu -&gt; Edit Dictionary Files -&gt; Servlet Properties. Find the options for &#39;Prior period column label&#39; and &#39;Current period column label&#39;. Recompile your application (you do not need to overwrite the HTML) to see the change.<\/li>\n<li class=\"padleft\">Fiscal dates are determined from the &#39;fiscal_month&#39; setting in the mrcjava\/WEB-INF\/classes\/mrc_runtime.properties file found on the m-Power server (i.e. fiscal_month=5). Tomcat needs to be restarted after the file change. This file will need to be promoted to production as well.<\/li>\n<li class=\"padleft\">This feature only supports true date fields. If wanting to use a datetime field, you will need to have a calculation created to convert the datetime to a date only field. For example; MSSQL database: CONVERT(DATE, [FIELD_HERE]). Use the new calculation as the record selection field.<\/li>\n<li class=\"padleft\">Period Analysis is supported in the following templates: Web 2.0 Report, Web 2.0 Report with Graph, OLAP Pivot Table, and the Interactive Report.<\/li>\n<\/ul>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Date Period Analysis The period analysis tool allows end-users the ability to quickly choose from a list of pre-set date values to filter reports. Common values include dates such as &#39;today&#39;, &#39;yesterday&#39;, and &#39;this week&#39; to more complicated date ranges such as &#39;last month to date&#39; and &#39;last fiscal quarter&#39;. Additionally, end-users are given the [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":557,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-8835","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.mrc-productivity.com\/legacy\/wp-json\/wp\/v2\/pages\/8835","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.mrc-productivity.com\/legacy\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.mrc-productivity.com\/legacy\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.mrc-productivity.com\/legacy\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.mrc-productivity.com\/legacy\/wp-json\/wp\/v2\/comments?post=8835"}],"version-history":[{"count":37,"href":"https:\/\/www.mrc-productivity.com\/legacy\/wp-json\/wp\/v2\/pages\/8835\/revisions"}],"predecessor-version":[{"id":9532,"href":"https:\/\/www.mrc-productivity.com\/legacy\/wp-json\/wp\/v2\/pages\/8835\/revisions\/9532"}],"up":[{"embeddable":true,"href":"https:\/\/www.mrc-productivity.com\/legacy\/wp-json\/wp\/v2\/pages\/557"}],"wp:attachment":[{"href":"https:\/\/www.mrc-productivity.com\/legacy\/wp-json\/wp\/v2\/media?parent=8835"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}