Hello,

My name is Christian and I am just beginning as a user of STATA. My question might be a bit silly, however I really need your help since I got stuck and I'm just learning this software. Well, I have a database where "a2" is a numeric variable that every observation such as Cordoba has a value of 4, Buenos Aires a value of 1 and so on. I need to assign a different value to each observation, therefore I created a new variable "ciudad". This new variable is a string variable and now I want to assign to these variable's observations different values, such as for Buenos Aires 9, Cordoba 10, Mendoza 11, etc.


Array

Once I got that done, I will drop "a2" because I need to append more data bases to this one with the same variables but with different scenarios and when I do it, the values overlap. For example, this data base is Argentina and when I append Bolivia, the values of "a2" overlap and the Bolivian cities such a La Paz, Sucre, etc that have the same values such as 4, 1, etc automatically are converted to Buenos Aires, Cordoba, etc adopting the values of the Argentinian Database.

How can I do it?

Thanks and kind regards.
Christian Rojas