Added mysql support to the code