Added database type patcher with tests