fixed db name handling