-- Run in phpMyAdmin → select database "motors_db" (NOT moters_db)
-- If you see "Duplicate column name" the column already exists — that is OK.

USE `motors_db`;

ALTER TABLE `garage_repair_orders`
    ADD COLUMN `meter_reading` DOUBLE(12,2) NULL DEFAULT NULL AFTER `garage_vehicle_id`;

ALTER TABLE `garage_sales`
    ADD COLUMN `meter_reading` DOUBLE(12,2) NULL DEFAULT NULL AFTER `garage_vehicle_id`;

ALTER TABLE `garage_estimates`
    ADD COLUMN `meter_reading` DOUBLE(12,2) NULL DEFAULT NULL AFTER `vehicle_id`;

-- If columns already exist as INT, convert to DOUBLE:
ALTER TABLE `garage_repair_orders` MODIFY `meter_reading` DOUBLE(12,2) NULL DEFAULT NULL;
ALTER TABLE `garage_sales` MODIFY `meter_reading` DOUBLE(12,2) NULL DEFAULT NULL;
ALTER TABLE `garage_estimates` MODIFY `meter_reading` DOUBLE(12,2) NULL DEFAULT NULL;

-- Verify:
-- SHOW COLUMNS FROM garage_estimates LIKE 'meter_reading';
-- SHOW COLUMNS FROM garage_repair_orders LIKE 'meter_reading';
-- SHOW COLUMNS FROM garage_sales LIKE 'meter_reading';
