Export MySQL error struct

Also export a MySQL error type struct for consistency