Fix swap data

Add unique identifier for each dataset.
Because Data is const in set_data