Database refactorisation