Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
st: merge problem
From
Alberto R Osella <[email protected]>
To
"[email protected]" <[email protected]>
Subject
st: merge problem
Date
Tue, 12 Mar 2013 12:26:38 +0100
Hi All,
I'm using Stata 12.1 on W7.
I'm trying to perform a consecutive merge.
I've tried:
use
E:\Alberto\Papers\WorkingPapers\Nutriepa\Nutriepa_Database\Nutriepa_Resto\Nutriepa_Dati.dta
drop dieta
merge 1:1 codice using
"E:\Alberto\Papers\WorkingPapers\Nutriepa\Nutriepa_Database\Nutriepa_Resto\Nutriepa_Quest_Generale.dta"
drop _merge
merge 1:1 codice using
"E:\Alberto\Papers\WorkingPapers\Nutriepa\Nutriepa_Database\Nutriepa_Resto\Nutriepa_Quest_Generale.dta"
drop _merge
save
E:\Alberto\Papers\WorkingPapers\Nutriepa\Nutriepa_Database\Nutriepa_Resto\Nutriepa_Generale.dta,
replace
clear
Also:
use
E:\Alberto\Papers\WorkingPapers\Nutriepa\Nutriepa_Database\Nutriepa_Resto\Nutriepa_Dati.dta
drop dieta
merge 1:1 codice using
"E:\Alberto\Papers\WorkingPapers\Nutriepa\Nutriepa_Database\Nutriepa_Resto\Nutriepa_Quest_Generale.dta"
drop _merge
save
E:\Alberto\Papers\WorkingPapers\Nutriepa\Nutriepa_Database\Nutriepa_Resto\Nutriepa_Generale.dta,
replace
clear
use
E:\Alberto\Papers\WorkingPapers\Nutriepa\Nutriepa_Database\Nutriepa_Resto\Nutriepa_Generale.dta
merge 1:1 codice using
E:\Alberto\Papers\WorkingPapers\Nutriepa\Nutriepa_Database\Nutriepa_Resto\Nutriepa_BMI_Dieta.dta
save
E:\Alberto\Papers\WorkingPapers\Nutriepa\Nutriepa_Database\Nutriepa_Resto\Nutriepa_Generale.dta,
replace
clear
But the code doesn't work. When Stata executes the second merge, it
always gives me the same error:
_merge already defined.
Can you help me?
Thanks.
--
Alberto R. Osella, MD, PhD
Laboratorio di Epidemiologia e Biostatistica
IRCCS Saverio de Bellis
Via Turi, 27
70013 Castellana Grotte (BA)
Italia
Tel: +39 0804994655
Fax: +39 0804994650
e-mail: [email protected]
____________
Controllo virus eseguito da G Data AntiVirus
Versione: AVA 22.8413 del 12.03.2013
Info nuovi virus: www.antiviruslab.com
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/