Hello! Help me please. I have a table, in the first column the hospital department is indicated, in the second - the patient code. There are 6 patients in the cardiology department, 4 patients in urology, 3 patients in dermatology, 1 patient in ophthalmology. How to make sure that there is a hospital department opposite each patient’s code? Those. In fact, I have a large database, and doing it manually will take a lot of time.

Code:
* Example generated by -dataex-. To install: ssc install dataex
clear
input long(department patient)
1  1
.  4
.  8
. 13
.  3
.  9
4 11
. 14
. 12
.  5
2  6
.  7
. 10
3  2
end
label values department departmen
label def departmen 1 "Cardiology", modify
label def departmen 2 "Dermatology", modify
label def departmen 3 "Ophtalmology", modify
label def departmen 4 "Urology", modify
label values patient patient