Database: updated selectionFactory to context