Add mysql table and a few fixes