media db fixed condition to delete derivation data