ALTER TABLE vehicle_trips
    ADD COLUMN IF NOT EXISTS driver_id INTEGER,
    ADD COLUMN IF NOT EXISTS start_time TIMESTAMP,
    ADD COLUMN IF NOT EXISTS end_time TIMESTAMP,
    ADD COLUMN IF NOT EXISTS status VARCHAR(20) DEFAULT 'Draft',
    ADD COLUMN IF NOT EXISTS start_mileage INTEGER,
    ADD COLUMN IF NOT EXISTS end_mileage INTEGER;
CREATE INDEX IF NOT EXISTS vehicle_trips_driver_idx ON vehicle_trips(driver_id);
CREATE INDEX IF NOT EXISTS vehicle_trips_status_idx ON vehicle_trips(status);
