How Storage Cleanup Works in iDempiere
The Storage Cleanup process in iDempiere is a utility designed to correct inventory imbalances within warehouse storage locations. When stock data becomes unbalanced—such as when a location shows negative on-hand quantity due to adjustments, transactions, or corrections—Storage Cleanup helps restore consistent storage records by generating internal inventory movements to offset and correct the misplaced quantities.
It does this by creating inventory movement documents that relocate stock from valid locations into those with negative balances, restoring the accuracy of storage levels in the system.
Inventory Imbalances
Inventory discrepancies can occur for multiple reasons, including data imports, manual adjustments, or transaction mismatches. A common issue is when a specific locator shows a negative on-hand quantity while the overall warehouse has stock in other locators. The system detects these situations by comparing actual on-hand quantities to expected storage levels.
Storage Cleanup Initiation
To run a cleanup, users open the Storage Cleanup process from the Material Management menu and provide a few key parameters, such as:
- Document Type — Specifies the type of internal movement document that will be created so that sequencing and processing rules apply correctly.
Once the process is started, iDempiere scans for storage records with imbalances and prepares the necessary internal movement documents to correct them.

Create Inventory Movements
When imbalances are found, the Storage Cleanup process does not directly adjust quantities in tables. Instead, it generates inventory movement transactions that represent physical stock relocations within the warehouse. These movements shift quantities from locations with positive stock to those with negative stock to neutralize inaccuracies.

In iDempiere, Storage Cleanup is a background utility that identifies and corrects storage location imbalances by generating internal inventory movement transactions. It ensures that negative on-hand quantities are addressed and that warehouse stock levels are accurate and reliable, supporting better inventory control and operational execution.