View previous topic :: View next topic
|
Author |
Message |
sqlcode1
Active Member
Joined: 08 Apr 2010 Posts: 577 Location: USA
|
|
|
|
Does the order of files in JOINKEY matter for Many to Many match(Cartesian Product)? I ask this question in relation to ICE428A error message.
Is it because while matching 2 files, dfsort takes all the records in a stack and keeps looking for match on a second file and later writting matched record to the final output? If my file1 has 10000 records and file2 has only 2 or 3 records for a key, it tries to put all 10000 records in a stack then later performing match. This will be improved only if we change the order where in DFSort takes 2 or 3 records in a stack and then performs match.
I am not asking for actual algorithm for DFSort processing but just asking if the order of file does matter. If it does matter, I would always use file with lesser number of dups as the first one for performance improvement.
Earlier I was having impression that file order doesn't really matter for joinkeys.
Please excuse me if my understanding is wrong as its a complete imagination of how DFSort would have behaved.
Thanks, |
|
Back to top |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
Given a choice, F1 should be used for the file with the MOST duplicates of one key. The details are proprietary, but I'll just say that the duplicates for F2 might need to be saved in storage. |
|
Back to top |
|
|
sqlcode1
Active Member
Joined: 08 Apr 2010 Posts: 577 Location: USA
|
|
|
|
Frank,
That gives me all the information I needed. Thanks a lot for the explanation.
Thanks |
|
Back to top |
|
|
|