一键导入
power-bi-salespulse-dashboard
Expert at implementing and customizing the SalesPulse 360 Power BI retail analytics dashboard for sales, profit, and regional analysis
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Expert at implementing and customizing the SalesPulse 360 Power BI retail analytics dashboard for sales, profit, and regional analysis
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Full-stack user management system with AI-powered analytics, risk detection, and task management capabilities
Full-stack user management system with AI-powered analytics for risk detection, burnout analysis, and ticket classification
Master the CommerceVault middleware for Easy Digital Downloads API integration, sales analytics, order management, and digital product orchestration.
MCP server for Easy Digital Downloads API integration enabling sales analytics, product management, and order orchestration
Master the CommerceVault middleware for Easy Digital Downloads API integration, sales analytics, and digital commerce orchestration
Build interactive Power BI sales dashboards with regional analysis, profit tracking, and predictive insights using the SalesPulse 360 framework
| name | power-bi-salespulse-dashboard |
| description | Expert at implementing and customizing the SalesPulse 360 Power BI retail analytics dashboard for sales, profit, and regional analysis |
| triggers | ["help me set up the SalesPulse 360 dashboard","how do I customize this Power BI sales dashboard","configure regional analytics in Power BI","add new metrics to this retail dashboard","troubleshoot Power BI data refresh issues","create a similar sales analytics dashboard","implement profit margin alerts in Power BI","localize this Power BI dashboard for multiple regions"] |
Skill by ara.so — Data Skills collection.
Expert guidance for implementing, customizing, and extending the SalesPulse 360 Power BI retail analytics dashboard. This skill covers data modeling, DAX formulas, visual customization, automated refresh configuration, and multi-regional deployment strategies for comprehensive sales and profit analysis.
SalesPulse 360 is a production-ready Power BI dashboard designed for retail analytics, featuring:
The dashboard transforms the Global Superstore dataset (or similar retail data) into actionable insights through interactive visualizations, dynamic filtering, and natural-language narratives.
git clone https://github.com/MahbubNibir/power-bi-retail-analytics-viz.git
cd power-bi-retail-analytics-viz
# Extract the compressed data file to a known location
unzip global-superstore-data.zip -d ./data/
# Launch Power BI Desktop and open the main file
start SalesPulse360.pbix
The dashboard uses a star schema with the following tables:
Total Sales = SUM(Sales[Sales Amount])
Profit Margin =
DIVIDE(
SUM(Sales[Profit]),
SUM(Sales[Sales Amount]),
0
)
YoY Sales Growth =
VAR CurrentYearSales = [Total Sales]
VAR PreviousYearSales =
CALCULATE(
[Total Sales],
DATEADD(Date[Date], -1, YEAR)
)
RETURN
DIVIDE(
CurrentYearSales - PreviousYearSales,
PreviousYearSales,
0
)
MAT Sales =
CALCULATE(
[Total Sales],
DATESINPERIOD(
Date[Date],
LASTDATE(Date[Date]),
-12,
MONTH
)
)
Profit Alert =
VAR CurrentMargin = [Profit Margin]
VAR ThresholdMargin = SELECTEDVALUE(Config[Profit Margin Threshold], 0.15)
RETURN
IF(
CurrentMargin < ThresholdMargin,
"⚠️ Below Threshold",
"✓ Healthy"
)
Sales Forecast =
VAR ForecastPeriod = 12
VAR HistoricalData =
CALCULATETABLE(
ADDCOLUMNS(
VALUES(Date[Date]),
"@Sales", [Total Sales]
),
Date[Date] <= MAX(Date[Date])
)
RETURN
// Use FORECAST.ETS or external R/Python script
FORECAST.ETS(
MAX(Date[Date]) + ForecastPeriod,
HistoricalData,
[Date],
[@Sales]
)
Regional Performance Index =
VAR RegionalSales = [Total Sales]
VAR GlobalAvgSales =
CALCULATE(
[Total Sales],
ALL(Geography[Region])
) / DISTINCTCOUNT(Geography[Region])
RETURN
DIVIDE(RegionalSales, GlobalAvgSales, 1) * 100
Customer Retention Rate =
VAR CurrentPeriodCustomers = DISTINCTCOUNT(Sales[Customer ID])
VAR PreviousPeriodCustomers =
CALCULATE(
DISTINCTCOUNT(Sales[Customer ID]),
DATEADD(Date[Date], -1, QUARTER)
)
VAR ReturningCustomers =
CALCULATE(
DISTINCTCOUNT(Sales[Customer ID]),
FILTER(
ALL(Date),
Date[Date] <= MAX(Date[Date]) &&
Date[Date] >= MIN(Date[Date])
)
)
RETURN
DIVIDE(ReturningCustomers, PreviousPeriodCustomers, 0)
Create a configuration table to store business rules:
// Configuration Table (manually entered or imported)
Config =
DATATABLE(
"Setting Name", STRING,
"Value", DOUBLE,
{
{"Profit Margin Threshold", 0.15},
{"Return Rate Warning", 0.08},
{"Rolling Average Days", 90},
{"Forecast Confidence Level", 0.95}
}
)
Implement field parameters for dynamic label switching:
// Language Selection (Create as Parameter)
Language = {
("English", NAMEOF(Language[English]), 0),
("Spanish", NAMEOF(Language[Spanish]), 1),
("French", NAMEOF(Language[French]), 2),
("German", NAMEOF(Language[German]), 3),
("Mandarin", NAMEOF(Language[Mandarin]), 4)
}
// Dynamic Label Measure
Sales Label =
SWITCH(
SELECTEDVALUE(Language[Ordinal]),
0, "Sales",
1, "Ventas",
2, "Ventes",
3, "Verkäufe",
4, "销售额",
"Sales" // Default
)
// Dynamic Currency Symbol
Currency Symbol =
VAR SelectedRegion = SELECTEDVALUE(Geography[Region])
RETURN
SWITCH(
SelectedRegion,
"North America", "$",
"Europe", "€",
"Asia Pacific", "¥",
"Latin America", "R$",
"$" // Default
)
// Formatted Sales with Currency
Formatted Sales =
VAR SalesValue = [Total Sales]
VAR Symbol = [Currency Symbol]
RETURN
Symbol & FORMAT(SalesValue, "#,##0.00")
Define security rules for regional access:
// RLS Rule for Geography Table
[Region] = USERNAME()
// Or for email-based assignment:
[Region] = LOOKUPVALUE(
UserRegionMapping[Region],
UserRegionMapping[Email],
USERPRINCIPALNAME()
)
Publish to Service:
Configure Gateway (for on-premises data):
Schedule Refresh:
Settings → Datasets → [Your Dashboard] → Scheduled Refresh
- Frequency: Daily
- Time: 02:00 UTC (or multiple times for near-real-time)
- Send failure notifications: [Your email]
Modify connection string for live querying:
// In Power Query Editor (Advanced Editor)
let
Source = Sql.Database(
"${DB_SERVER}",
"${DB_NAME}",
[
Query="SELECT * FROM SalesTransactions WHERE TransactionDate >= DATEADD(year, -2, GETDATE())",
CommandTimeout=#duration(0, 0, 5, 0)
]
)
in
Source
Average Order Value =
DIVIDE(
[Total Sales],
DISTINCTCOUNT(Sales[Order ID]),
0
)
Create a tooltip page with detailed breakdowns:
// Tooltip Measures
Tooltip - Top Products =
CONCATENATEX(
TOPN(
3,
VALUES(Product[Product Name]),
[Total Sales],
DESC
),
Product[Product Name] & ": " & FORMAT([Total Sales], "$#,##0"),
UNICHAR(10) // Line break
)
Dynamic Title =
VAR SelectedRegion = SELECTEDVALUE(Geography[Region], "All Regions")
VAR SelectedCategory = SELECTEDVALUE(Product[Category], "All Categories")
RETURN
"Sales Performance - " & SelectedRegion & " | " & SelectedCategory
Apply color scales based on performance:
// Color Measure for Profit Margin
Profit Margin Color =
VAR Margin = [Profit Margin]
RETURN
SWITCH(
TRUE(),
Margin >= 0.20, "#28a745", // Green
Margin >= 0.15, "#ffc107", // Yellow
Margin >= 0.10, "#fd7e14", // Orange
"#dc3545" // Red
)
Create a visual flag for underperforming segments:
Alert Count =
VAR LowMarginRegions =
COUNTROWS(
FILTER(
VALUES(Geography[Region]),
[Profit Margin] < 0.15
)
)
VAR HighReturnCategories =
COUNTROWS(
FILTER(
VALUES(Product[Category]),
[Return Rate] > 0.08
)
)
RETURN
LowMarginRegions + HighReturnCategories
Alert Details =
CONCATENATEX(
FILTER(
VALUES(Geography[Region]),
[Profit Margin] < 0.15
),
Geography[Region] & " margin at " & FORMAT([Profit Margin], "0.0%"),
", "
)
// Create calculated table for scenarios
Scenarios =
DATATABLE(
"Scenario", STRING,
"Growth Rate", DOUBLE,
{
{"Conservative", 0.05},
{"Expected", 0.10},
{"Optimistic", 0.15}
}
)
// Scenario-adjusted forecast
Scenario Sales Forecast =
VAR BaselineSales = [Total Sales]
VAR GrowthRate = SELECTEDVALUE(Scenarios[Growth Rate], 0.10)
RETURN
BaselineSales * (1 + GrowthRate)
Error: "Data source connection failed"
Solution:
// Test connection in Power Query
let
Source = Csv.Document(
File.Contents("${DATA_PATH}/sales.csv"),
[Delimiter=",", Columns=21, Encoding=65001, QuoteStyle=QuoteStyle.None]
)
in
Source
Symptoms: Visuals take >5 seconds to load
Solutions:
// Limit to recent 2 years
Filtered Sales =
CALCULATE(
[Total Sales],
Date[Year] >= YEAR(TODAY()) - 2
)
// Pre-aggregate by month and category
let
Source = Sales,
Grouped = Table.Group(
Source,
{"Year", "Month", "Category"},
{
{"Total Sales", each List.Sum([Sales Amount]), type number},
{"Total Profit", each List.Sum([Profit]), type number}
}
)
in
Grouped
Problem: Totals don't match sum of filtered rows
Solution: Use ALLSELECTED instead of ALL:
Percentage of Total =
DIVIDE(
[Total Sales],
CALCULATE([Total Sales], ALLSELECTED()),
0
)
Problem: Users see all data despite RLS rules
Checklist:
Problem: FORECAST.ETS throws "insufficient data" error
Solution:
Sales Forecast Safe =
VAR MinDataPoints = 24 // Need 2 years minimum
VAR DataPointCount = COUNTROWS(FILTER(ALL(Date), NOT(ISBLANK([Total Sales]))))
RETURN
IF(
DataPointCount >= MinDataPoints,
[Sales Forecast],
BLANK() // Return blank if insufficient data
)
Enable Excel integration for advanced analysis:
' VBA code to refresh Power BI data in Excel
Sub RefreshPowerBIData()
Dim conn As WorkbookConnection
For Each conn In ThisWorkbook.Connections
conn.Refresh
Next conn
MsgBox "Data refreshed successfully"
End Sub
Use Power BI Embedded API:
// JavaScript for embedding dashboard
const embedConfig = {
type: 'report',
id: '${POWERBI_REPORT_ID}',
embedUrl: 'https://app.powerbi.com/reportEmbed',
accessToken: '${POWERBI_ACCESS_TOKEN}', // Use OAuth flow
settings: {
filterPaneEnabled: true,
navContentPaneEnabled: true,
localeSettings: {
language: 'en-US',
formatLocale: 'en-US'
}
}
};
const embedContainer = document.getElementById('reportContainer');
const report = powerbi.embed(embedContainer, embedConfig);
Push real-time data to streaming dataset:
import requests
import os
def push_sales_data(transaction_data):
"""Push transaction data to Power BI streaming dataset"""
api_url = f"https://api.powerbi.com/beta/{os.environ['POWERBI_TENANT_ID']}/datasets/{os.environ['DATASET_ID']}/rows?key={os.environ['POWERBI_API_KEY']}"
payload = {
"rows": [
{
"OrderID": transaction_data["order_id"],
"Sales": transaction_data["amount"],
"Profit": transaction_data["profit"],
"Timestamp": transaction_data["timestamp"]
}
]
}
response = requests.post(api_url, json=payload)
return response.status_code == 200
Data Model Optimization:
DAX Performance:
Visual Design:
Security:
Maintenance:
This skill provides comprehensive coverage of implementing and extending the SalesPulse 360 dashboard for enterprise retail analytics scenarios.