Initial (workin) comit mysql backend

Implemented first version of MySQL backend.
Minor changes in the backend interface.