M
Marcia
You might consider making (WorsiteID, SessionTime) a unique key..
I tried this. I deleted the fldSessionID in tblWorksiteSessions, then
made the fldWorksiteID and fldSessionTime BOTH the primary key. It
wouldn't let me link them to the fldDailySessionID (in
tblDailySessions), though. Said.. "No unique index found for the
referenced field of the primary table." How do you link a combination
of TWO fields to ONE?
This still gives me a Syntax error. (I did try it BEFORE I attempted
to re-work the tblWorksiteSessions primary keys).
I have been able to do this part in the query design grid, though (I
posted a picture of the two query designs):
http://postedinfo.homestead.com/index.html
In my many previous attempts, I would then try to make this query the
basis of a third "crosstab" query so I could get the horizontal layout
they wanted; but when I tried to insert the crosstab query into my
report, I always got the error message about how I couldn't use a
"pass-through" query.
I'm all for making it simpler! <g> Tell me the process for linking
TWO primary keys to ONE primary key, and I'll do it.
Sorry so complicated,
Jessi
I tried this. I deleted the fldSessionID in tblWorksiteSessions, then
made the fldWorksiteID and fldSessionTime BOTH the primary key. It
wouldn't let me link them to the fldDailySessionID (in
tblDailySessions), though. Said.. "No unique index found for the
referenced field of the primary table." How do you link a combination
of TWO fields to ONE?
SELECT tblWorksites.fldWorskiteID,
tblDailySessions.fldResidentID
FROM tblWorksites
LEFT OUTER JOIN (tblWorksiteSessions
LEFT OUTER JOIN (tblDailySessions
ON tblDailySessions.fldDailySessionID
= tblWorksiteSessions.fldSessionID)
ON tblWorksiteSessions.fldWorksiteID = tblWorksites.fldWorksiteID)
This still gives me a Syntax error. (I did try it BEFORE I attempted
to re-work the tblWorksiteSessions primary keys).
If it doesn't work, then you should be able to build this bit
in the query grid by adding each table in turn: Worksites ->
WorksiteSessions -> DailySessions.
I have been able to do this part in the query design grid, though (I
posted a picture of the two query designs):
http://postedinfo.homestead.com/index.html
In my many previous attempts, I would then try to make this query the
basis of a third "crosstab" query so I could get the horizontal layout
they wanted; but when I tried to insert the crosstab query into my
report, I always got the error message about how I couldn't use a
"pass-through" query.
As an aside, if you had decided to use (Worksite, SessionTime) as the PK
for the WorksiteSessions table, and (Worksite, SessionTime, ResidentID) as
the PK for the DailySessions table, then this would not have required any
joins at all!
I'm all for making it simpler! <g> Tell me the process for linking
TWO primary keys to ONE primary key, and I'll do it.
Sorry so complicated,
Jessi