SADIQSOFT

HVAC Products & Services

Legacy ERP Modernization

Upgraded legacy ERP for performance, scalability, and clearer sales reporting.

10s → <200ms
Inventory search speed
Next-day → Real-time
Financial report freshness
<4 hours
Migration downtime
10+ years
Historical data migrated

Challenge

The same HVAC company's core ERP system was a legacy application originally deployed over a decade earlier. It had been extended through years of ad-hoc customisation into a system that was slow, difficult to maintain, and impossible to integrate with modern tools. Inventory search across 50,000+ product SKUs took 8–12 seconds. Financial reports required overnight batch processing and were available only the following morning. The system could not be extended to support mobile access, API integration, or the AI support layer described in the previous case study.

Solution

SADIQSOFT rebuilt the ERP on a modern architecture — Laravel backend, Next.js frontend, PostgreSQL database with optimised indexing — while preserving all existing business logic and migrating all historical data. The migration was executed in parallel with the live legacy system, with a final cutover window of under four hours and zero data loss.

Data Migration Architecture

Migrating over a decade of inventory, sales, procurement, and financial records required a carefully sequenced extraction, transformation, and loading process. SADIQSOFT built a custom migration pipeline that ran continuously for six weeks before cutover, keeping the new system synchronised with the live legacy system. During this period, the team identified and resolved data quality issues — duplicate records, inconsistent categorisation, orphaned transactions — that had accumulated over years of manual data entry.

Inventory Search Performance

The legacy system's inventory search was built on a full-table scan query against an unindexed VARCHAR field. With 50,000+ SKUs and a decade of transaction history attached to each record, this query took 8–12 seconds on a good day and timed out under load. The new system uses PostgreSQL full-text search with a pre-computed tsvector index on product name, SKU code, brand, and category. Search queries return results in under 200 milliseconds regardless of concurrent user count.

Real-Time Financial Reporting

Financial reports in the legacy system were generated by a nightly batch job that aggregated transaction records into summary tables. This meant that the P&L, the balance sheet, and the branch-level margin reports were always one day behind. In the new system, financial reports are generated in real time from the live transaction ledger using pre-aggregated materialised views that refresh on a configurable schedule — defaulting to every 15 minutes. Branch managers see current-day financials during the business day.

Multi-Branch Architecture

The legacy system was a single-tenant application with no native support for multi-branch operations. Branch separation was implemented through a naming convention in the product codes and a manual filter in the reporting queries. The new system has a first-class multi-branch data model. Every transaction is tagged to a branch. Inventory levels, sales figures, and financial balances are tracked independently per branch and consolidated at the company level. Intercompany transfers between branches are handled as proper accounting entries.

API Layer for Future Integrations

The new ERP exposes a comprehensive REST API with OAuth 2.0 authentication. This API layer is what makes the AI support agent integration possible — the agent reads product data, checks service scheduling, and creates job records through the same API that the web interface uses. Future integrations, whether with an e-commerce storefront, a supplier EDI connection, or an additional AI layer, can be built against this API without touching the core application code.

  • Migrated 10+ years of inventory records with zero downtime
  • Real-time multi-branch financial reporting
  • Sub-second search queries across 50,000+ SKUs