fix some bug on create database