James Muller <[email protected]> said:
> I have noticed a little problem with non-unique merging, when the sort
> option is used. Sort appears to set the 'unique master' option. I'll
> give an example:
>
> <cut>
>
> The error I receive is that "variable id does not uniquely identify
> observations in the master data". If re-run the above example except
> manually sort each dataset and do not set the sort option then it
> returns a warning rather than an error.
>
> The help on merge describes the 'unique' option as options as, if
> specified then uniqueness is a requirement but otherwise it is not. I
> quote:
>
> <cut>
>
> There is nothing said in the description of the sort option. And so
> the above example should produce the dataset:
>
> <cut>
>
> It isn't anything serious, I know, but it's not the stated behaviour
> for merge.
Look at the options table under the syntax diagram in -help
merge- (or in the manual for [D] merge). At the bottom of that
table it says
sort implies unique.
So it is not a bug. But, it looks like we should state this
again down in the options section. I will see about changing
merge.hlp (and eventually the manual) so that in the description
of the -sort- option down in the Options section it will also say
this.
Ken Higbee [email protected]
StataCorp 1-800-STATAPC
*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/