jonnycattt
Registered User.
- Local time
- Today, 15:23
- Joined
- Sep 29, 2001
- Messages
- 20
Hi all,
I've got a paramater query prompting me for 4 paramaters. The problem is that it prompts me for each of them two times. I've tried various combinations of parentheses, but to no avail.
Below is the query. Any ideas?
Thanks.
Marc
Here's the query:
SELECT PlantTOC.TOCID, Dockets.Month, Dockets.Year, Plant2002.Editorial, Plant2002.FirstAuthor, Plant2002.PrintPages, Plant2002.CM, DateDiff("d",Plant2002.FromEdOffice,(select ScheduleDate from Schedule_Master where EventTypeID=1 and Schedule_Master.DocketNumber = Plant2002.DocketNumber )) AS AvgVsDeadline, Plant2002.FromEdOffice, (select ScheduleDate from Schedule_Master where EventTypeID=1 and Schedule_Master.DocketNumber = Plant2002.DocketNumber ) AS ScheduleLastDay, (select ScheduleDate from Schedule_Master where EventTypeID=7 and Schedule_Master.DocketNumber = Plant2002.DocketNumber ) AS ScheduleMailDate
FROM PlantTOC RIGHT JOIN (Dockets INNER JOIN Plant2002 ON Dockets.DocketNumber = Plant2002.DocketNumber) ON PlantTOC.TOCID = Plant2002.TOCID
WHERE Dockets.Volume Between [Enter Start Volume] And [Enter End volume] AND Dockets.Issue Between [Enter Start issue] And [Enter End Issue] AND PlantTOC.TOCID<>21
ORDER BY Dockets.Year DESC , Dockets.Volume, Dockets.Issue, Plant2002.FromEdOffice DESC , Plant2002.CM;
I've got a paramater query prompting me for 4 paramaters. The problem is that it prompts me for each of them two times. I've tried various combinations of parentheses, but to no avail.
Below is the query. Any ideas?
Thanks.
Marc
Here's the query:
SELECT PlantTOC.TOCID, Dockets.Month, Dockets.Year, Plant2002.Editorial, Plant2002.FirstAuthor, Plant2002.PrintPages, Plant2002.CM, DateDiff("d",Plant2002.FromEdOffice,(select ScheduleDate from Schedule_Master where EventTypeID=1 and Schedule_Master.DocketNumber = Plant2002.DocketNumber )) AS AvgVsDeadline, Plant2002.FromEdOffice, (select ScheduleDate from Schedule_Master where EventTypeID=1 and Schedule_Master.DocketNumber = Plant2002.DocketNumber ) AS ScheduleLastDay, (select ScheduleDate from Schedule_Master where EventTypeID=7 and Schedule_Master.DocketNumber = Plant2002.DocketNumber ) AS ScheduleMailDate
FROM PlantTOC RIGHT JOIN (Dockets INNER JOIN Plant2002 ON Dockets.DocketNumber = Plant2002.DocketNumber) ON PlantTOC.TOCID = Plant2002.TOCID
WHERE Dockets.Volume Between [Enter Start Volume] And [Enter End volume] AND Dockets.Issue Between [Enter Start issue] And [Enter End Issue] AND PlantTOC.TOCID<>21
ORDER BY Dockets.Year DESC , Dockets.Volume, Dockets.Issue, Plant2002.FromEdOffice DESC , Plant2002.CM;