Skip to content

Write ID Mapper-Script | PuzzleTime Sync #2 #735

Closed
@RandomTannenbaum

Description

@RandomTannenbaum

Introduction
At the moment we have the problem that we have no way of knowing which record from the PuzzleSkills DB belongs to which record from the PuzzleTime DB. We can't do this by name or similar because we can't ensure these are atomic and consistent with our data. To solve this problem we have to map the values initially, so we later know if a record is new or already exists.

To know this we essentially want a foreign key on every person record in PuzzleSkills that references the primary keys from person records in PuzzleTime. So the first step is to create a db migration to add this new field.

For the initial mapping an idea was to write a mapper script that tries to find as many matching records as possible by using an attribute like the name. The matches that are unambiguous can then be mapped automatically. Ambiguous matches or unmatched entries should be sorted out by the script for manual mapping and confirmation.

ToDo

  • Add a field to the PuzzleSkills db with a name like puzzletime_id
  • Write a mapper script that maps the IDs from PuzzleTime to the puzzletime_id fields in PuzzleSkills by an Attribute like name.
  • Manually map or find another Method for the IDs that cannot be mapped automatically.
  • Tests

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions