Register the DM with a transaction should a query fail.