<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Inventory turnover ratio in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Inventory-turnover-ratio/m-p/2999030#M101179</link>
    <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="343948" data-lia-user-login="IvanS" class="lia-mention lia-mention-user"&gt;IvanS&lt;/a&gt; , check if isinscope and closingbalancemonth and openingbalancemonth&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Power Bi DAX Functions openingbalancemonth, openingbalancequarter, openingbalanceyear, firstnonblankvalue, and parallelperiod. Opening Stock, First value of period: &lt;A href="https://youtu.be/6lzYOXI5wfo" target="_blank"&gt;https://youtu.be/6lzYOXI5wfo&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Power BI Allocating Targets- closingbalancemonth, closingbalancequarter, closingbalanceyear:&lt;A href="https://youtu.be/yPQ9UV37LOU" target="_blank"&gt;https://youtu.be/yPQ9UV37LOU&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;use isinscope to switch between month, qtr, and year&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.kasperonbi.com/use-isinscope-to-get-the-right-hierarchy-level-in-dax/" target="_blank"&gt;https://www.kasperonbi.com/use-isinscope-to-get-the-right-hierarchy-level-in-dax/&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 03 Jan 2023 16:31:13 GMT</pubDate>
    <dc:creator>amitchandak</dc:creator>
    <dc:date>2023-01-03T16:31:13Z</dc:date>
    <item>
      <title>Inventory turnover ratio</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Inventory-turnover-ratio/m-p/2998488#M101131</link>
      <description>&lt;P&gt;Hi guys,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;I found some posts about calculation of Inventory Turnover ratio (ITR) but unfortunately none of them have solution posted. Therefore I would like to have one post with the final answer to help also other users.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Here is the business need - to calculate Inventory Turnover ratio on monthly, quarterly and yearly basis &amp;amp; per product &amp;amp; per warehouse.&amp;nbsp;We want to also calculate ITR for all months/quarters/years so we can visualize the trends.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Tables available:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;1) Monthly Item Inventory (purpose of this table is to store the inventory figures at the end of each month) with following columns:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Date (31.12.2022, 30.11.2022 etc)&lt;/LI&gt;&lt;LI&gt;Product ID&lt;/LI&gt;&lt;LI&gt;Warehouse ID&lt;/LI&gt;&lt;LI&gt;Quantity&lt;/LI&gt;&lt;LI&gt;Value of stock&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;2) Item Ledger (this table captures all items of Items - purchases, sales, internal transfers) with following columns:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Date (date of transation)&lt;/LI&gt;&lt;LI&gt;Transaction Type (Sale, Purchase, Transfer)&lt;/LI&gt;&lt;LI&gt;Product ID&lt;/LI&gt;&lt;LI&gt;Warehouse ID&lt;/LI&gt;&lt;LI&gt;Quantity&lt;/LI&gt;&lt;LI&gt;Price&lt;/LI&gt;&lt;LI&gt;Value of transacion (= Quantity * Price)&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Calculation of&amp;nbsp;Inventory Turnover ratio - formula for ITR is following:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ITR = Cost of Goods sold&amp;nbsp;/ Average Inventory&lt;BR /&gt;&lt;SPAN&gt;Average Inventory = ( &lt;/SPAN&gt;&lt;SPAN&gt;Value of stock at &lt;/SPAN&gt;&lt;STRONG&gt;start&lt;/STRONG&gt;&lt;SPAN&gt; of period +&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;Value of stock at &lt;/SPAN&gt;&lt;STRONG&gt;end&lt;/STRONG&gt;&lt;SPAN&gt; of period ) / 2&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Cost of Goods sold = sum of values of transaction (where transfer type = "Sale") in &lt;STRONG&gt;specific period&lt;/STRONG&gt; (see below)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Coming back to the business need, we need to calculate Inventory Turonver ratio of several time period:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Monthly - in this case we want to calculate ITR for &lt;U&gt;previous calendar month&lt;/U&gt; and calculation will look like:&lt;BR /&gt;&lt;P&gt;Sum of values of transaction (sales) sold from &lt;STRONG&gt;1.12.2022 to 31.12.2022&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Average Inventory = ( Value of stock at &lt;STRONG&gt;30.11.2022&lt;/STRONG&gt;&amp;nbsp;+&amp;nbsp;Value of stock at &lt;STRONG&gt;31.12.2022&lt;/STRONG&gt;&amp;nbsp;) / 2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;The same logic applies for month-2, month-3, month-4 etc.&lt;BR /&gt;&lt;BR /&gt;&lt;/LI&gt;&lt;LI&gt;Quarterly - in this case we want to calculate ITR for &lt;U&gt;previous calendar quarter&lt;/U&gt; (Q4/2022) and calculation will look like:&lt;BR /&gt;&lt;P&gt;Sum of values of transaction (sales) sold from &lt;STRONG&gt;1.10.2022 to 31.12.2022&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Average Inventory = ( Value of stock at &lt;STRONG&gt;30.9.2022&lt;/STRONG&gt;&amp;nbsp;+&amp;nbsp;Value of stock at &lt;STRONG&gt;31.12.2022&lt;/STRONG&gt;&amp;nbsp;) / 2&lt;BR /&gt;The same logic applies for Q3/2022, Q2/2022, Q1/2022, Q4/2021 etc.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;Yearly - in this case we want to calculate ITR for &lt;U&gt;previous calendar year&lt;/U&gt; and calculation will look like:&lt;BR /&gt;&lt;P&gt;Sum of values of transaction (sales) sold from &lt;STRONG&gt;1.1.2022 to 31.12.2022&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Average Inventory = ( Value of stock at &lt;STRONG&gt;31.12.2021&lt;/STRONG&gt;&amp;nbsp;+&amp;nbsp;Value of stock at &lt;STRONG&gt;31.12.2022&lt;/STRONG&gt;&amp;nbsp;) / 2&lt;BR /&gt;The same logic applies for years 2021, 2020 etc&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you for any inputs. I tried to be as specific as possible but if you have any questions, just let me know.&lt;/P&gt;&lt;P&gt;IvanS&lt;/P&gt;</description>
      <pubDate>Tue, 03 Jan 2023 12:11:12 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Inventory-turnover-ratio/m-p/2998488#M101131</guid>
      <dc:creator>IvanS</dc:creator>
      <dc:date>2023-01-03T12:11:12Z</dc:date>
    </item>
    <item>
      <title>Re: Inventory turnover ratio</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Inventory-turnover-ratio/m-p/2999030#M101179</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="343948" data-lia-user-login="IvanS" class="lia-mention lia-mention-user"&gt;IvanS&lt;/a&gt; , check if isinscope and closingbalancemonth and openingbalancemonth&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Power Bi DAX Functions openingbalancemonth, openingbalancequarter, openingbalanceyear, firstnonblankvalue, and parallelperiod. Opening Stock, First value of period: &lt;A href="https://youtu.be/6lzYOXI5wfo" target="_blank"&gt;https://youtu.be/6lzYOXI5wfo&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Power BI Allocating Targets- closingbalancemonth, closingbalancequarter, closingbalanceyear:&lt;A href="https://youtu.be/yPQ9UV37LOU" target="_blank"&gt;https://youtu.be/yPQ9UV37LOU&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;use isinscope to switch between month, qtr, and year&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.kasperonbi.com/use-isinscope-to-get-the-right-hierarchy-level-in-dax/" target="_blank"&gt;https://www.kasperonbi.com/use-isinscope-to-get-the-right-hierarchy-level-in-dax/&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Jan 2023 16:31:13 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Inventory-turnover-ratio/m-p/2999030#M101179</guid>
      <dc:creator>amitchandak</dc:creator>
      <dc:date>2023-01-03T16:31:13Z</dc:date>
    </item>
    <item>
      <title>Re: Inventory turnover ratio</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Inventory-turnover-ratio/m-p/3006973#M101789</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="148838" data-lia-user-login="amitchandak" class="lia-mention lia-mention-user"&gt;amitchandak&lt;/a&gt;&amp;nbsp;&amp;nbsp;,&amp;nbsp;&lt;/P&gt;&lt;P&gt;Many thanks for your suggestions.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;For monthly % change, I have manage to calculate the average inventory by calculating Inventory at the end of last month and one month before the last month - please see below:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Inventory Current Month = 
CLOSINGBALANCEMONTH ( 
SUM (nav_FACT_MonthlyItemInventory[Total_Value] ), 
nav_FACT_MonthlyItemInventory[Date]) 


Inventory Previous Month = CLOSINGBALANCEMONTH( 
SUM (nav_FACT_MonthlyItemInventory[Total_Value] ), 
DATEADD(nav_FACT_MonthlyItemInventory[Date], -1, MONTH))&lt;/LI-CODE&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;However, I am having issues with calculating the sum of "Sale" transations from Item ledger so I get the numbers for each month. For some reason, the CLOSINGBALANCEMONTH is working only for months which have transaction on last day of month.&lt;BR /&gt;&lt;BR /&gt;Could you please provide your thoughts on how to create DAX function on this?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;P&gt;IvanS&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 07 Jan 2023 15:21:26 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Inventory-turnover-ratio/m-p/3006973#M101789</guid>
      <dc:creator>IvanS</dc:creator>
      <dc:date>2023-01-07T15:21:26Z</dc:date>
    </item>
  </channel>
</rss>

