<font size=2 face="sans-serif">I understand. Mine hurt figuring it out.
;-)</font>
<br>
<br>
<br>
<br><font size=1 color=#5f5f5f face="sans-serif">From: &nbsp; &nbsp; &nbsp;
&nbsp;</font><font size=1 face="sans-serif">&quot;Johnson, Tracy&quot;
&lt;Tracy.Johnson@meas-spec.com&gt;</font>
<br><font size=1 color=#5f5f5f face="sans-serif">To: &nbsp; &nbsp; &nbsp;
&nbsp;</font><font size=1 face="sans-serif">PowerHouse listserver
&lt;powerh-l@lists.sowder.com&gt;</font>
<br><font size=1 color=#5f5f5f face="sans-serif">Date: &nbsp; &nbsp; &nbsp;
&nbsp;</font><font size=1 face="sans-serif">03/06/2015 08:13 AM</font>
<br><font size=1 color=#5f5f5f face="sans-serif">Subject: &nbsp; &nbsp;
&nbsp; &nbsp;</font><font size=1 face="sans-serif">RE: Hierarchical
vs. Parallel linkage</font>
<br><font size=1 color=#5f5f5f face="sans-serif">Sent by: &nbsp; &nbsp;
&nbsp; &nbsp;</font><font size=1 face="sans-serif">powerh-l-bounces+mohmes=us.ibm.com@lists.sowder.com</font>
<br>
<hr noshade>
<br>
<br>
<br><font size=2 color=#002060 face="Century Gothic">My brain hurts thinking
about it.</font>
<br><font size=2 color=#002060 face="Century Gothic">&nbsp;</font>
<br><font size=2 color=#002060 face="Century Gothic"><b>Tracy Johnson</b></font>
<br><font size=2 color=#002060 face="Century Gothic">00 1 757 766 4318
tel</font>
<br><font size=2 color=#002060 face="Century Gothic">00 1 757 755-6470
mobile</font>
<br><font size=2 color=#002060 face="Century Gothic">&nbsp;</font>
<br><font size=2 face="Tahoma"><b>From:</b> powerh-l-bounces+tracy.johnson=meas-spec.com@lists.sowder.com
[</font><a href="mailto:powerh-l-bounces+tracy.johnson=meas-spec.com@lists.sowder.com"><font size=2 face="Tahoma">mailto:powerh-l-bounces+tracy.johnson=meas-spec.com@lists.sowder.com</font></a><font size=2 face="Tahoma">]
<b>On Behalf Of </b>Matt Ohmes<b><br>
Sent:</b> Thursday, March 05, 2015 6:57 PM<b><br>
To:</b> PowerHouse listserver<b><br>
Subject:</b> Hierarchical vs. Parallel linkage</font>
<br><font size=3 face="Times New Roman">&nbsp;</font>
<br><font size=2 face="Courier New">Hi all,</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
I promised I would write up something on the differences between Hierarchical
and Parallel linkage in Quiz (and QTP), so here we go. (And for those of
you who know all this already, please forgive my trip down memory lane.)</font><font size=3 face="Times New Roman">
<br>
</font><font size=2 face="Courier New"><br>
Oh, and I'm assuming no bugs in the product regarding syntax. :-)</font><font size=3 face="Times New Roman">
<br>
</font><font size=2 face="Courier New"><br>
Differences between Hierarchical and Parallel linkage in Quiz (and QTP)</font><font size=3 face="Times New Roman">
<br>
</font><font size=2 face="Courier New"><br>
In all examples below, we will use 3 files. Assume all are indexed files,
keyed on Emp_No</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
File Employees: 5 records;</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
Emp_No &nbsp;Emp_Name</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; Bob</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
2 &nbsp; &nbsp; &nbsp; Mary</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
3 &nbsp; &nbsp; &nbsp; Pat</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
4 &nbsp; &nbsp; &nbsp; Kim</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
5 &nbsp; &nbsp; &nbsp; Sean</font><font size=3 face="Times New Roman">
<br>
</font><font size=2 face="Courier New"><br>
File Paychecks: 5 records</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
Emp_No &nbsp;Pay_Date &nbsp; &nbsp;Amt</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; 2015-01-01 &nbsp;100 &nbsp; &nbsp; (Bob)</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; 2015-01-15 &nbsp;200 &nbsp; &nbsp; (Bob)</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
2 &nbsp; &nbsp; &nbsp; 2015-01-01 &nbsp;300 &nbsp; &nbsp; (Mary)</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
2 &nbsp; &nbsp; &nbsp; 2015-01-15 &nbsp;400 &nbsp; &nbsp; (Mary)</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
3 &nbsp; &nbsp; &nbsp; 2015-01-15 &nbsp;600 &nbsp; &nbsp; (Pat)</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
Note: 4 Kim and 5 Sean just started and have not been paid yet)</font><font size=3 face="Times New Roman">
<br>
</font><font size=2 face="Courier New"><br>
File Dependents: 4 records;</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
Emp_No &nbsp;Dep_Name</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; Bob Jr &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp;(Bob's 1st dependent)</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; Bobbie &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp;(Bob's 2nd dependent)</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
2 &nbsp; &nbsp; &nbsp; Marie &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; (Mary's dependent)</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
5 &nbsp; &nbsp; &nbsp; Shawn &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; (Sean's dependent)</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
Note: 3 Pat and 4 Kim do not have any dependents</font><font size=3 face="Times New Roman">
<br>
</font><font size=2 face="Courier New"><br>
This will be my Report statement for ALL examples:</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
Report &amp;</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;Emp_No of Employees &amp;</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;Emp_Name of Employees &amp;</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;Pay_Date of Paychecks &amp;</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;Amt of Paychecks &amp;</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;Dep_Name of Dependents</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;<br>
First Hierarchical linkage:</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
Access Employees &amp;</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;Link Emp_No of Employees to Emp_No of Paychecks &amp;</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;Link Emp_No of Employees to Emp_No of Dependents</font><font size=3 face="Times New Roman">
<br>
</font><font size=2 face="Courier New"><br>
Emp_No &nbsp;Emp_Name &nbsp; &nbsp;Pay_Date &nbsp; &nbsp;Amt &nbsp; &nbsp;
Dep_Name</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; Bob &nbsp; &nbsp; &nbsp; &nbsp; 2015-01-01 &nbsp;100
&nbsp; &nbsp; Bob Jr</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; Bob &nbsp; &nbsp; &nbsp; &nbsp; 2015-01-01 &nbsp;100
&nbsp; &nbsp; Bobbie</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; Bob &nbsp; &nbsp; &nbsp; &nbsp; 2015-01-15 &nbsp;200
&nbsp; &nbsp; Bob Jr</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; Bob &nbsp; &nbsp; &nbsp; &nbsp; 2015-01-15 &nbsp;200
&nbsp; &nbsp; Bobbie</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
2 &nbsp; &nbsp; &nbsp; Mary &nbsp; &nbsp; &nbsp; &nbsp;2015-01-01 &nbsp;300
&nbsp; &nbsp; Marie</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
2 &nbsp; &nbsp; &nbsp; Mary &nbsp; &nbsp; &nbsp; &nbsp;2015-01-15 &nbsp;400
&nbsp; &nbsp; Marie</font><font size=3 face="Times New Roman"> <br>
</font><font size=2 face="Courier New"><br>
Obvious problems. Pat, Kim, and Sean are not showing up at all because
no files are optional. I'm assuming the use of Optional in hierarchical
linkage is well understood so I won't go into that discussion here. This
post is about parallel linkage. :-)</font><font size=3 face="Times New Roman">
<br>
</font><font size=2 face="Courier New"><br>
A bigger problem with the report is that paycheck and dependent records
are being duplicated. Hierarchical linkage is simply wrong for this data;
the results make no sense. <br>
 </font><font size=3 face="Times New Roman">&nbsp;</font><font size=2 face="Courier New"><br>
Using hierarchical linkage for this data is essentially saying, for each
paycheck an employee has received, read down the list of all their dependents.
That makes no sense. Just as it would make no sense to say, for each dependent
an employee has, show me every time they have been paid. &nbsp;The number
of paychecks I receive is based on how long I have worked for my employeer,
not how many dependents I have. &nbsp;Similarly, the number of dependents
I have is not based on how long I have worked for my employer. &nbsp;</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
 </font><font size=3 face="Times New Roman">&nbsp;</font><font size=2 face="Courier New"><br>
Paychecks and Dependents are both, obviously related to Employees, but
they are NOT RELATED TO ONE ANOTHER. &nbsp;</font><font size=3 face="Times New Roman">
<br>
</font><font size=2 face="Courier New"><br>
Instead of one of these files &quot;driving&quot; the other, they should
be read in parallel; i.e. at the same time. &nbsp;THIS is why we have parallel
linkage. &nbsp;Parallel linkage is saying, for each employee, show me each
of their paychecks AND each of their dependents.</font><font size=3 face="Times New Roman">
<br>
</font><font size=2 face="Courier New"><br>
Let's try parallel linkage in the Access statement and what that does to
our report results.</font><font size=3 face="Times New Roman"> <br>
</font><font size=2 face="Courier New"><br>
Access Employees &amp;</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;Link Emp_No of Employees to Emp_No of Paychecks &amp;</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;AND Emp_No of Employees to Emp_No of Dependents <br>
 &nbsp; &nbsp;<br>
Emp_No &nbsp;Emp_Name &nbsp; &nbsp;Pay_Date &nbsp; &nbsp;Amt &nbsp; &nbsp;
Dep_Name</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; Bob &nbsp; &nbsp; &nbsp; &nbsp; 2015-01-01 &nbsp;100
&nbsp; &nbsp; Bob Jr</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; Bob &nbsp; &nbsp; &nbsp; &nbsp; 2015-01-15 &nbsp;200
&nbsp; &nbsp; Bobbie</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
2 &nbsp; &nbsp; &nbsp; Mary &nbsp; &nbsp; &nbsp; &nbsp;2015-01-01 &nbsp;300
&nbsp; &nbsp; Marie</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
2 &nbsp; &nbsp; &nbsp; Mary &nbsp; &nbsp; &nbsp; &nbsp;2015-01-15 &nbsp;400</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
3 &nbsp; &nbsp; &nbsp; Pat &nbsp; &nbsp; &nbsp; &nbsp; 2015-01-15 &nbsp;600</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
5 &nbsp; &nbsp; &nbsp; Sean &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Shawn</font><font size=3 face="Times New Roman">
<br>
</font><font size=2 face="Courier New"><br>
This makes more sense for this data. &nbsp;Each paycheck is reported once
and each dependent is reported once. &nbsp;</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
Notice, as long as there is at least one record FROM ANY of the parallel
files you get a record complex returned. Parallel files are, more or less,
&quot;semi-optional&quot;.</font><font size=3 face="Times New Roman"> <br>
</font><font size=2 face="Courier New"><br>
However, also notice employee 4 Kim was not reported. &nbsp;This was because
Kim did not have any paychecks (yet) or dependents. If you want to see
Kim on the report as well, make ANY of the parallel files optional; it
doesn't make any difference which one because of the &quot;semi-optional&quot;
nature of parallel files.</font><font size=3 face="Times New Roman"> <br>
</font><font size=2 face="Courier New"><br>
Access Employees &amp;</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;Link Emp_No of Employees to Emp_No of Paychecks &amp;</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;AND Emp_No of Employees to Emp_No of Dependents Optional</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
 &nbsp; &nbsp;<br>
Emp_No &nbsp;Emp_Name &nbsp; &nbsp;Pay_Date &nbsp; &nbsp;Amt &nbsp; &nbsp;
Dep_Name</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; Bob &nbsp; &nbsp; &nbsp; &nbsp; 2015-01-01 &nbsp;100
&nbsp; &nbsp; Bob Jr</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
1 &nbsp; &nbsp; &nbsp; Bob &nbsp; &nbsp; &nbsp; &nbsp; 2015-01-15 &nbsp;200
&nbsp; &nbsp; Bobbie</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
2 &nbsp; &nbsp; &nbsp; Mary &nbsp; &nbsp; &nbsp; &nbsp;2015-01-01 &nbsp;300
&nbsp; &nbsp; Marie</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
2 &nbsp; &nbsp; &nbsp; Mary &nbsp; &nbsp; &nbsp; &nbsp;2015-01-15 &nbsp;400</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
3 &nbsp; &nbsp; &nbsp; Pat &nbsp; &nbsp; &nbsp; &nbsp; 2015-01-15 &nbsp;600</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
4 &nbsp; &nbsp; &nbsp; Kim</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
5 &nbsp; &nbsp; &nbsp; Sean &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Shawn</font><font size=3 face="Times New Roman">
<br>
</font><font size=2 face="Courier New"><br>
To be honest, parallel linkage is not that common. It is fair to ask, &quot;If
two files aren't related to one another, why are you writing a report with
both of them on it?&quot; &nbsp;But it does have its uses from time to
time.</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
 </font><font size=3 face="Times New Roman">&nbsp;</font><font size=2 face="Courier New"><br>
I hope that explanation helps. (It was fun writing about good old Quiz
again after all these years.)</font><font size=3 face="Times New Roman">
</font><font size=2 face="Courier New"><br>
Cheers,</font><font size=3 face="Times New Roman"> </font><font size=2 face="Courier New"><br>
Matt</font><tt><font size=2>--<br>
= = = = = = = = = = = = = = = = = = = = = = = = = = = =<br>
Mailing list: powerh-l@lists.sowder.com<br>
Subscribe: 'subscribe' in message body to powerh-l-request@lists.sowder.com<br>
Unsubscribe: 'unsubscribe &amp;lt;password&amp;gt;' in message body to
powerh-l-request@lists.sowder.com<br>
</font></tt><a href="http://lists.sowder.com/mailman/listinfo/powerh-l"><tt><font size=2>http://lists.sowder.com/mailman/listinfo/powerh-l</font></tt></a><tt><font size=2><br>
This list is closed, thus to post to the list you must be a subscriber.<br>
Add 'site:lists.sowder.com powerh-l' to your search terms to search the
list archive at Google.</font></tt>
<br>