Add unique indexes to dataset_in_pools, snapshot_in_pools and in_branches
Transfer chain: fix snapshot in pool creation