Report & Subreport

  • Thread starter Thread starter XMan
  • Start date Start date
No they don't.

--

Gary Miller
Gary Miller Computer Services
Sisters, OR
________________________
 
Can main query have other linked tables?

Here's my main report query:
SELECT *
FROM (PROCESS_CYCLES AS PC RIGHT JOIN ((DIALOG_TYPES AS DT INNER JOIN
DIALOGS AS D ON DT.DIALOG_TYPE_UI = D.DIALOG_TYPE_UI) LEFT JOIN TEAMS AS ACT
ON D.ACCOUNTABLE_TEAM_UI = ACT.TEAM_UI) ON PC.PROCESS_CYCLE_UI =
D.PROCESS_CYCLE_UI) INNER JOIN (TEAMS AS ADT RIGHT JOIN ADVISORY_REVIEWS AS
AR ON ADT.TEAM_UI = AR.TEAM_UI) ON D.DIALOG_UI = AR.DIALOG_UI
WHERE (((DT.DESCRIPTION)='Decision') AND ((AR.REQUIRED_DISCUSSION)='YES'))
ORDER BY ADT.NAME, D.DIALOG_UI;

Here's the subreport query:
SELECT *
FROM GUIDING_PRINCIPLES RIGHT JOIN DIALOG_PRINCIPLES ON
GUIDING_PRINCIPLES.GUIDING_PRINCIPLE_UI =
DIALOG_PRINCIPLES.GUIDING_PRINCIPLE_UI;

I link these two reports with D.DIALOG_UI and DIALOG_PRINCIPLES.DIALOG_UI.

When I run the report it's asking for value for D. Just can't figure out
what's the problem here.

Thanks for your help.
 
I don't see "DIALOG_PRINCIPLES.DIALOG_UI" in either query,
so how are you using it to link? I would suggest that you
take the table reference out and just use DIALOG_UI as the
link in the Master/Child settings, but I don't see any
DIALOG_UI in the second query.
--

Gary Miller
Gary Miller Computer Services
Sisters, OR
________________________
 
Your problem may be the use of D.DIALOG_UI as the link. The Alias is valid
within the query but not within the form code.

Try using DIALOGS.DIALOG_UI instead.

Rod
 
That SELECT * was the cause. I had to do SELECT fieldname1, fieldname2. I
had to specified the fields I need in the SELECT statement and it works.
Thanks for your time looking into this.
 
Back
Top