add sql script and configure database