Hello!

I am trying to merge two datasets from a survey which contains household ((HH) level data with different variables and thus value labels. First of all, I had to convert these datasets from SPSS to Stata, and then merging them through its common identificator name as, let's say, id. Thus, I used the following command:

use household.dta, clear

merge 1:1 id using using.dta

This succesfully merges the two datasets, but the problem is that the labels of the variables are changed. For example, before merging the datasets, we could have two variables as follows:

HH_A: Categorical variable in master dataset that takes the values of
1 = "X"
2 = "Y"
3 = "Z"

HH_1: Categorical variable in using dataset that takes the values of
1 = "A"
2 = "B"
3 = "C"

When both datasets are merged, HH_1 wrongly takes the value labels of the variable in the master dataset, so that for the values that are equal to 1 the label showed in the merged dataset is X, for 2 "Y" and for 3 "Z", which does not make any sense. How could I fix this? I already tried to reformulate the command so that:

use using.dta, clear

merge 1:1 id using household.dta, nolabel

as nolablel is supposed to order Stata not to copy value-label definitions from using, but this does not work either and the value labels are mixed again but the other way around.

I thank you for the guidance in advance!

Best,
Michelle