Date: Thu, 20 Feb 1997 14:24:59 -0800
Reply-To: redmanj@lloyds-bank.co.uk
Sender: "SAS(r) Discussion" <SAS-L@UGA.CC.UGA.EDU>
From: James Redman <redmanj@LLOYDS-BANK.CO.UK>
Organization: Lloyds TSB Group
Subject: Merging two tables with duplicates in each
Content-Type: text/plain; charset=us-ascii
Hi all,
I have two tables that I would like to merge together to get all
possible combinations. For example :-
Table1 Table2
X Y X Z
---------------------------------
a 1 a 3
a 2 a 4
b 5 b 7
c 6 c 8
And would like to merge it into a table :-
Merged
X Y Z
-----------------
a 1 3
a 1 4
a 2 3
a 2 4
b 5 7
c 6 8
I am having great trouble getting the 4 obs where X='a'. All my attempts
only come back with 2.
Can anyone help.
Thanks in anticipation,
James.
|