Solution for mysql db connection