As the error so esquisitely mentions - the table already belongs to a dataset. So basically, like a god handing out lives, you can't take someone elses and try to call it your own.

Since I forgot to bring my omniscient powers to work today - you'll have to post the rest of your code.