Adding copy functionality for db and multivalue improvements