A number of mysql to mysqli conversions