RRN and JOIN…
15 pts.
0
Q:
RRN and JOIN...
I have two files and I'd like to join and make a group-by on a xycod, in order to count the number of occurrences. This is the question: What happens on the RRN filed when i try to do group by statement? There is one-to-many relation between records and RRNs, so which is the RRN assigned to it?
ASKED: Oct 13 2008  1:27 PM GMT
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
0
24570 pts.
0
A:
 RATE THIS ANSWER
0
Click to Vote:
  •   0
  •  0
  • AddThis Social Bookmark Button
I'n not sure what you are doing.
Sounds like you are doing an SQL join.
Why does the RRN matter?
If it's so you can determine the XYCOD wouldn't this statement do it?


Select count(*), a.XYCOD
from tablea a join tableb b
on a.XYCOD = b.XYCOD
group by XYCOD
Last Answered: Oct 13 2008  2:51 PM GMT by Philpl1jb   24570 pts.
0
0
Discuss This Answer:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _



_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

Devilva   15 pts.  |   Oct 14 2008  3:22PM GMT

yes, i’m doing a SQL join…and ok, the role of RRN is not relevant to obtain the result of statement.
it’s a conceptual curiosity only…
infact there are many “one-to-many” relation between records and RRNs, and i’d like to know which is the RRN assigned…
for example max(RRN(<file>))

 

Philpl1jb   24570 pts.  |   Oct 14 2008  5:19PM GMT

Well, I think they have created a temp file so the RRN’s of that file would have no relationship to either parent file.

 
0