Hi there. I’m thinking about creating a database using an excel file from a hospital equipment inventory a while ago. the main there is a sample from the many tables in the attached image. the columns are:
- code - given by the hospital and found in a tag pasted on the equipment
- location - where the equipment was found at the time the inventory was taken (won’t be using it)
- name - name of the equipment
- brand - brand of the equipment
- model - model of the equipment
- serial number - found on the equipment
- does it work? - this was done to keep track of which ones had to receive maintenance
- observations - text space to specify missing pieces, visible damage, etc.
I’m planing to use MS SQL server management to do this project. So my question is: I’m thinking of using the code as primary key, given every device has its own. thing is, some of the devices are really old and the painting, tags and other identifiers have come off or even the personnel takes them off (don’t ask me why ) so if I can’t generate a primary key in the same way as they did how can I adjust my PK to fit the pattern? (many devices are missing the code so taking them out is not an option). I thought of generating a new PK and leaving the code as another column but I don’t know if that is a good practice.
Any of you guys have any recommendations?
thank you for reading