Opaque keys migrate

@cpennington @dianakhuang refactored migration script.

Diana, it'd be great if you could help me debug why user 17 is not migrated on your sandbox. I'll try to load your tables into mine and see if I can reproduce locally first.