I'm not sure what result you are looking for, but I think that the
fields you chose for linking sound perfectly reasonable.
What I would do next is try some troubleshooting methods like this:
Display these 2 fields in your BAQ and rerun it:
LaborDtl.LaborHedSeq and
LaborDtl.LaborDtlSeq.
LaborDtl.Company plus LaborHedSeq plus LaborDtlSeq should represent a
single unique record in your LaborDtl table. If your BAQ is
returning more than 1 record for each LaborHedSeq+LaborDtlSeq, then
there is a linking error somewhere.
If there is only 1 row returned, then your linking is probably fine.
In that case, there is probably something wrong with your logic.
Displaying additional fields from the tables will help you determine
why you are getting more rows than you are expecting.
Print out the Data Dictionary for each of your 3 tables to help you
decide what additional fields to display for troubleshooting purposes.
Also, in my experience, the BAQ phrase builder can be stubborn. I
have found that it helps if I close the BAQ and re-open it from the
menu frequently while troubleshooting a complicated BAQ. It seems to
give it a "boot" and "get rid of any old bad memory shadows".
A side note: I assume that since you are not using the Company field
for linking that you do not have the Multi-company module. However,
it is always a good practice to include the Company field in all of
your relationships.
Lynn
--- In vantage@yahoogroups.com, "brucewbrannan" <bruce.brannan@...>
wrote:
fields you chose for linking sound perfectly reasonable.
What I would do next is try some troubleshooting methods like this:
Display these 2 fields in your BAQ and rerun it:
LaborDtl.LaborHedSeq and
LaborDtl.LaborDtlSeq.
LaborDtl.Company plus LaborHedSeq plus LaborDtlSeq should represent a
single unique record in your LaborDtl table. If your BAQ is
returning more than 1 record for each LaborHedSeq+LaborDtlSeq, then
there is a linking error somewhere.
If there is only 1 row returned, then your linking is probably fine.
In that case, there is probably something wrong with your logic.
Displaying additional fields from the tables will help you determine
why you are getting more rows than you are expecting.
Print out the Data Dictionary for each of your 3 tables to help you
decide what additional fields to display for troubleshooting purposes.
Also, in my experience, the BAQ phrase builder can be stubborn. I
have found that it helps if I close the BAQ and re-open it from the
menu frequently while troubleshooting a complicated BAQ. It seems to
give it a "boot" and "get rid of any old bad memory shadows".
A side note: I assume that since you are not using the Company field
for linking that you do not have the Multi-company module. However,
it is always a good practice to include the Company field in all of
your relationships.
Lynn
--- In vantage@yahoogroups.com, "brucewbrannan" <bruce.brannan@...>
wrote:
>but
> Wait... it only fixed part of it.
>
> All of the operations show up now (even with zero hours applied)
> the labor hours are grossly inflated.it
>
> It seems like the new join is backward. JobOper is related to
> LaborDtl on Company, JobNum, AssemblySeq, and OpSeq. I wonder if
> is quadrupling the labor records for each field (redundant joins?).<bruce.brannan@>
>
> --- In vantage@yahoogroups.com, "brucewbrannan" <bruce.brannan@>
> wrote:
> >
> > You're both right, I didn't notice that box. That fixed it.
> >
> > Thanks!
> >
> > --- In vantage@yahoogroups.com, "Lynn" <lynn.khalife@> wrote:
> > >
> > > Don't resort to ODBC. There are too many reasons to use BAQs
> > instead
> > > of ODBC.
> > >
> > > It sounds like you just forgot to check the "Outer Join" box on
> > your
> > > relationship between tables JobOper & LaborDtl.
> > >
> > > Lynn
> > >
> > > --- In vantage@yahoogroups.com, "brucewbrannan"
> > > wrote:report
> > > >
> > > > I've got a BAQ with JobHead, JobOper, and LaborDtl. The
> > ison
> > > used
> > > > to show the Operation hour estimates alongside the hours
> charged
> > to
> > > the
> > > > operation from the labor entries. The Crystal report works
> great
> > > but
> > > > it only shows the operations that have hours charged to them.
> > > >
> > > > This sounds like a join problem but within the Phrase Builder
> in
> > > BAQs,
> > > > I can't figure out how to change the join. I have JobHead
> linked
> > > to
> > > > JobOper on the JobNum. And then JobOper to LaborDtl linked
> > > JobNum,having
> > > > Asy, and Oper fields and. I can see why this only shows Ops
> > where
> > > > there is labor applied but I don't know how to fix it using
> > Phrase
> > > > Builder. My next attempt is to rebuild the report in Crystal
> > using
> > > > ODBC but I'd rather stick with the BAQ report to prevent
> > to
> > > > setup ODBC on all of our client PCs.
> > > >
> > > > Any ideas?
> > > >
> > > > Thanks
> > > >
> > >
> >
>