<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Perfality eCommerce Brief]]></title><description><![CDATA[Perfality eCommerce Brief]]></description><link>https://perfalityecom.hashnode.dev</link><generator>RSS for Node</generator><lastBuildDate>Thu, 12 Nov 2026 08:09:46 GMT</lastBuildDate><atom:link href="https://perfalityecom.hashnode.dev/rss.xml" rel="self" type="application/rss+xml"/><language><![CDATA[en]]></language><ttl>60</ttl><item><title><![CDATA[Build a Power BI Model for Amazon and Walmart Sales and Ad Data]]></title><description><![CDATA[If you sell on more than one marketplace, your numbers live in separate reports: sales exports, advertising reports and inventory files. This tutorial…]]></description><link>https://perfalityecom.hashnode.dev/build-a-power-bi-model-for-amazon-and-walmart-sales-and-ad-data</link><guid isPermaLink="true">https://perfalityecom.hashnode.dev/build-a-power-bi-model-for-amazon-and-walmart-sales-and-ad-data</guid><category><![CDATA[PowerBI]]></category><category><![CDATA[data analytics]]></category><dc:creator><![CDATA[Perfality]]></dc:creator><pubDate>Wed, 04 Nov 2026 09:50:49 GMT</pubDate><content:encoded><![CDATA[<p>If you sell on more than one marketplace, your numbers live in separate reports: sales exports, advertising reports and inventory files. This tutorial shows a simple star-schema model in Power BI and the DAX measures that answer the most common questions: how are sales trending, is advertising efficient, and how long will stock last.</p>
<p>The column names below are examples. Marketplace report formats change, so map them to the files you actually export.</p>
<h2>1. The tables</h2>
<p>Load each report as its own table (CSV exports work fine) and clean the column names in Power Query.</p>
<table>
<thead>
<tr>
<th>Table</th>
<th>Type</th>
<th>Key columns</th>
</tr>
</thead>
<tbody><tr>
<td>FactSales</td>
<td>Fact</td>
<td>Date, Marketplace, SKU, Units, Sales</td>
</tr>
<tr>
<td>FactAds</td>
<td>Fact</td>
<td>Date, Marketplace, SKU, Spend, AdSales, Clicks, Impressions</td>
</tr>
<tr>
<td>FactInventory</td>
<td>Fact (daily snapshot)</td>
<td>Date, Marketplace, SKU, EndingUnits</td>
</tr>
<tr>
<td>DimDate</td>
<td>Dimension</td>
<td>Date, Month, Quarter, Year</td>
</tr>
<tr>
<td>DimProduct</td>
<td>Dimension</td>
<td>SKU, Title, Brand, Category</td>
</tr>
<tr>
<td>DimMarketplace</td>
<td>Dimension</td>
<td>Marketplace</td>
</tr>
</tbody></table>
<p>Tips for the load step:</p>
<ul>
<li>Use the same SKU text in every file (trim spaces, fix case). Most broken dashboards come from mismatched SKUs.</li>
<li>Make sure Date is a real date type in every table.</li>
<li>Create DimDate with <code>CALENDARAUTO()</code> or a date table from Power Query, and mark it as the date table.</li>
</ul>
<h2>2. The relationships</h2>
<p>Use a star schema: each dimension connects to each fact table with a one-to-many relationship, filtering in one direction (dimension to fact).</p>
<ul>
<li>DimDate[Date] to FactSales[Date], FactAds[Date], FactInventory[Date]</li>
<li>DimProduct[SKU] to FactSales[SKU], FactAds[SKU], FactInventory[SKU]</li>
<li>DimMarketplace[Marketplace] to the Marketplace column of each fact table</li>
</ul>
<p>Do not connect fact tables to each other. Slicers on the dimensions then filter all of them at once.</p>
<h2>3. Core measures</h2>
<pre><code class="language-dax">Total Sales = SUM ( FactSales[Sales] )

Units = SUM ( FactSales[Units] )

Ad Spend = SUM ( FactAds[Spend] )

Ad Sales = SUM ( FactAds[AdSales] )

ACOS = DIVIDE ( [Ad Spend], [Ad Sales] )

ROAS = DIVIDE ( [Ad Sales], [Ad Spend] )

TACoS = DIVIDE ( [Ad Spend], [Total Sales] )
</code></pre>
<p>What they tell you:</p>
<ul>
<li><strong>ACOS</strong> is ad spend as a share of ad-attributed sales. Lower is better.</li>
<li><strong>ROAS</strong> is the same relationship flipped: sales per dollar of ad spend.</li>
<li><strong>TACoS</strong> compares ad spend to total sales, so it shows whether advertising is growing faster than the business.</li>
</ul>
<h2>4. Trend measures</h2>
<pre><code class="language-dax">Sales Prior Month =
CALCULATE ( [Total Sales], DATEADD ( DimDate[Date], -1, MONTH ) )

Sales MoM % =
DIVIDE ( [Total Sales] - [Sales Prior Month], [Sales Prior Month] )
</code></pre>
<p>Put DimDate[Month] on a line chart axis and these two measures will show growth and slowdowns without any manual comparison.</p>
<h2>5. Inventory measures</h2>
<p>Inventory is a snapshot, so you should not add it up across days. Take the last value in the selected period instead:</p>
<pre><code class="language-dax">Ending Inventory =
CALCULATE ( SUM ( FactInventory[EndingUnits] ), LASTDATE ( DimDate[Date] ) )

Daily Units =
DIVIDE ( [Units], DISTINCTCOUNT ( FactSales[Date] ) )

Days of Cover =
DIVIDE ( [Ending Inventory], [Daily Units] )

Sell-Through % =
DIVIDE ( [Units], [Units] + [Ending Inventory] )
</code></pre>
<p>Days of Cover estimates how many days the current stock will last at the recent selling pace. Sell-Through % shows how much of the available stock actually sold in the period.</p>
<h2>6. A simple report layout</h2>
<ul>
<li>Top row: cards for Total Sales, Units, ACOS, ROAS, Days of Cover</li>
<li>Middle: line chart of Total Sales and Ad Spend by month, with a Marketplace slicer</li>
<li>Bottom: table by SKU showing Total Sales, ACOS and Days of Cover, sorted by Total Sales</li>
</ul>
<p>Add conditional formatting to the SKU table, for example red when Days of Cover is below your reorder lead time.</p>
<h2>7. Check your numbers</h2>
<p>Before sharing the report:</p>
<ol>
<li>Compare Total Sales for one month with the marketplace's own sales report.</li>
<li>Compare Ad Spend with the advertising console.</li>
<li>Check for SKUs that appear in the facts but not in DimProduct, since they will show as blank.</li>
</ol>
<p>If the totals do not match, the cause is usually a date or time zone difference, or a missing file for part of the month.</p>
<h2>8. Refreshing the data</h2>
<p>For a first version, replace the CSV files in a shared folder and use the Folder connector so Power BI picks up new files. When you outgrow manual exports, move to scheduled refresh using the marketplace APIs or a data warehouse.</p>
<hr />
<p><em>We build marketplace dashboards like this at <a href="https://perfality.com/?utm_source=hashnode&amp;utm_medium=referral&amp;utm_campaign=powerbi-tutorial">Perfality</a>. For a non-technical overview aimed at store owners, see our article <a href="https://perfality.com/2025/09/04/ecommerce-power-bi-dashboard/?utm_source=hashnode&amp;utm_medium=referral&amp;utm_campaign=powerbi-tutorial">Stop Guessing, Start Growing: Power BI for E-Commerce Success</a>.</em></p>
]]></content:encoded></item></channel></rss>