fix select dialog from db