A full-stack logistics analytics project from raw relational schema to interactive Tableau dashboards uncovering $262M in revenue patterns, fleet performance, and operational efficiency across 3 years of freight data. This dashboard uses a logistics datasets from Kaggle.com.
Truck Express operates a large-scale freight network across the United States, managing over 120 trucks, 150 drivers, and thousands of monthly loads across dozens of origin-destination lanes. Despite generating over $262M in revenue across 2022–2024, the company lacked a unified analytics layer to understand where that revenue was coming from, and more critically, where costs were eroding it.
The operational data existed but was fragmented across 14 relational database tables spanning drivers, trucks, trailers, customers, routes, loads, trips, fuel purchases, maintenance records, delivery events, safety incidents, facilities, driver monthly metrics and truck utilization metrics. No single view tied these together into actionable insight.
This project was designed to bridge that gap — transforming raw relational data into a 7-page interactive intelligence platform that operations, finance, and executive teams can actually use.
Underpriced lanes and high-cost routes silently drain margin. Analytics makes the invisible visible.
Fuel accounted for $95.59M of operating cost, a 1% efficiency gain saves ~$1M annually.
23% of the fleet sits idle at any given time, each idle truck is lost revenue that can be recovered.
Top drivers generate 2x the revenue of bottom-tier drivers. Knowing who is who changes HR decisions.
14 Raw Tables
7 Optimized Views
The raw schema was a normalized relational database built for transactional integrity, not analytical consumption. Each table served a specific operational purpose but had no awareness of the broader business picture. The first engineering challenge was designing a transformation layer that preserved data accuracy while making it analytically usable.
MySQL views were chosen over flat tables to ensure the analytical layer always reflects the most current underlying data.
Mapped all 14 table relationships — one-to-one, one-to-many, and many-to-one — to identify correct join paths and avoid row duplication in aggregated views.
Tables like fuel_purchases and maintenance_records were aggregated via subqueries and CTEs before joining to base tables, preventing row multiplication in merged views.
Revenue per mile, fuel cost per mile, operating ratio, incident rate per 100 trips, driver tenure, and performance tiers were all computed directly in SQL using arithmetic expressions, DATEDIFF, and NTILE window functions.
Each view was scoped to a specific dashboard page — one view per page — keeping Tableau queries lean, fast, and purpose-built for their visualization context.
Row counts, revenue totals, and cost sums were cross-validated against base table aggregates to confirm the views produced accurate, non-duplicated results before connecting to Tableau.
Once the 7 views were validated in MySQL, they were connected directly to Tableau Public as live data sources. Each view fed a dedicated dashboard page, keeping the workbook clean and the visualization logic separated from the data transformation logic.
Every metric on every dashboard page is backed by a purpose-written query — from single KPI aggregates to multi-join ranked lists and time-series trend tables.
Each dashboard page opens with 4–5 headline KPIs — total revenue, operating ratio, on-time rate, incident rate — giving stakeholders an instant top-line read before diving into charts.
Revenue per mile, performance tier classification, operating ratio, and on-time rate were computed as Tableau calculated fields layered on top of the SQL views for interactive flexibility.
A consistent dark navy palette (#1A1A2E background, #03C4A1 primary, #C62B88 accent) was applied across all 7 pages, with color encoding carrying analytical meaning throughout.
Year, booking type, route, driver tier, and incident type filters are connected across sheets via Tableau dashboard actions, enabling drill-down exploration without leaving the page.
Fuel cost per location is visualized on a US state-level filled map, giving operations teams an immediate geographic view of where fuel spend is concentrated.
Each dashboard page answers a specific business question, from executive revenue oversight to safety compliance designed to serve different organizational stakeholders.
Six findings that cut through the noise and tell the real story of this freight operation.
Total revenue of $262.53M against $101.23M in operating costs produces a strong headline. However, the 44.60% on-time delivery rate suggests significant service-level risk — customers experiencing late deliveries may negotiate lower rates or leave, threatening future revenue without immediately showing in cost metrics.
The revenue per mile spread between the best lane (PA-NY at $2.78) and worst lane (NV-NY at $1.53) is 82% — meaning the worst lane generates almost half the revenue per mile of the best. With 58 routes in the network, standardizing lane pricing to even approach the median would materially improve total revenue.
At $95.59M, fuel represents 94.3% of total operating cost — dwarfing maintenance at $5.73M. This concentration means fleet-wide MPG improvement, smarter fueling location selection, and route optimization against fuel-cost corridors are far more impactful than any maintenance efficiency program.
With 28 trucks sitting idle at any given time and an average revenue per truck of $79.16K, the theoretical revenue opportunity from recovering idle capacity is over $2.2M — without hiring a single new driver or acquiring a single new truck. Idle reduction is the fastest path to revenue growth in this fleet.
With 124 drivers split near-evenly across three performance tiers, one-third of the driver base (the low performer tier) is generating significantly below-average revenue. The top 10 drivers alone contribute an estimated $23M+ — roughly 8.7% of total revenue from fewer than 10% of drivers. This concentration creates operational fragility.
64 of 170 incidents over 3 years were classified as preventable — meaning they could have been avoided with better training, protocol adherence, or vehicle maintenance. At the average incident cost of $15.6K per preventable incident, eliminating them entirely saves roughly $332K per year in damage, legal, and compliance costs.
Here is how each finding translates into concrete operational and financial outcomes.
Six data-backed strategic decisions, each with a clear verdict and rationale drawn directly from the analysis.
No — not before addressing the 23% idle rate. With 28 trucks already generating zero revenue, adding trucks without solving dispatch inefficiency and route coverage gaps would only increase fixed costs. The priority is maximizing utilization of the existing 120-truck fleet first. Revisit acquisition when idle rate drops below 10%.
No — not before addressing the on-time rate. The 44.60% on-time rate is not a capacity problem; it is a scheduling, routing, or driver quality problem. Adding drivers to a broken process amplifies the problem. The focus should be upskilling the Low Performer tier (41 drivers) and addressing the root causes of late deliveries before expanding headcount.
Yes — this is the highest-ROI initiative available. The $1.25/mile gap between the best and worst lanes, combined with the geographic concentration of high-cost fueling states, means route optimization delivers both revenue uplift (better lane pricing) and cost reduction (lower fuel spend) simultaneously. Start with the bottom 10 underperforming lanes.
Yes — this is effectively free revenue. The 28 idle trucks represent over $2.2M in recoverable revenue capacity with no additional capital expenditure. Implementing dynamic load matching, reducing empty mile runs, and tightening dispatch scheduling are all operational levers that pay back immediately.
Yes — 37.65% preventable incident rate is both a cost problem ($332K/year) and a regulatory risk. DOT Violations are the most frequent incident type, which carries insurance premium implications beyond direct damage costs. A targeted compliance and defensive driving program for the highest-risk driver cohort has a highly favorable cost-benefit ratio.
Yes — but on a data-driven schedule. The Truck Age vs Maintenance Cost scatter identifies specific trucks above the cost inflection point. Rather than a blanket fleet renewal, a targeted retirement of the top 10–15 highest-maintenance trucks in the next 12–18 months reduces unplanned downtime, lowers per-mile maintenance cost, and improves driver satisfaction on newer equipment.
Based on 3 years of observed patterns, here is what the data signals about where this business is heading.
The near-flat monthly revenue trend across 2022–2024 — oscillating between $6.57M and $7.72M — suggests a mature, stable demand base. Without new lane expansion or customer acquisition, 2025 revenue is projected to remain in the $7.0–7.5M/month range. Meaningful growth requires either new customer wins or rate increases on existing lanes.
Dedicated loads have maintained ~10,500 per quarter across all four quarters for 3 years with zero seasonal degradation. This segment will continue to anchor revenue. The strategic play is converting high-frequency spot customers (like First Logistics at 2,116 loads) to dedicated contracts — locking in volume and improving planning certainty.
The truck age distribution indicates a meaningful portion of the fleet is entering the 7–11 year range — historically the zone where maintenance cost acceleration begins. Without a structured retirement and renewal plan, maintenance spend (currently $5.73M) could increase 20–35% over the next 3 years, compressing margins.
Fuel prices showed significant month-to-month volatility throughout the analysis period. With fuel at 94.3% of operating costs, a 10% fuel price increase translates to approximately $9.6M in additional annual cost. Fuel hedging or surcharge pass-through mechanisms with customers deserve serious consideration as a risk management strategy.
From the raw MySQL schema to the interactive Tableau dashboards — every layer of this project is available to explore. Connect with me if you want to discuss the methodology, the findings, or how this kind of analysis applies to your operation.