AlisonEmmett
Technical User
I am running the same database from two different Access Programs (both same version - 97). I have a query that uses two other joined queries to pull back data. In one version rows are returned, and not in the other. THIS MAKES NO SENSE TO ME !!!!
The SQL for the joining query is as follows:
SELECT StatQ1.Server, StatQ1.Time, Avg(StatQ1.StatBefore) AS AvgOfStatBefore, Avg(StatQ2.StatAfter) AS AvgOfStatAfter
FROM StatQ1 INNER JOIN StatQ2 ON (StatQ1.Server = StatQ2.Server) AND (StatQ1.Time = StatQ2.Time)
GROUP BY StatQ1.Server, StatQ1.Time;
STATQ1 is as follows:
SELECT Stats.Server, Stats.Time, Avg(Stats.Memory) AS StatBefore
FROM Stats
GROUP BY Stats.Server, Stats.Time, Stats.Date
HAVING (((Stats.Server)='julie1') AND ((Stats.Date)<#8/31/2000#));
STATQ2 is:
SELECT Stats.Server, Stats.Time, Avg(Stats.Memory) AS StatAfter
FROM Stats
GROUP BY Stats.Server, Stats.Time, Stats.Date
HAVING (((Stats.Server)='julie1') AND ((Stats.Date)>#8/31/2000#));
[sig][/sig]
The SQL for the joining query is as follows:
SELECT StatQ1.Server, StatQ1.Time, Avg(StatQ1.StatBefore) AS AvgOfStatBefore, Avg(StatQ2.StatAfter) AS AvgOfStatAfter
FROM StatQ1 INNER JOIN StatQ2 ON (StatQ1.Server = StatQ2.Server) AND (StatQ1.Time = StatQ2.Time)
GROUP BY StatQ1.Server, StatQ1.Time;
STATQ1 is as follows:
SELECT Stats.Server, Stats.Time, Avg(Stats.Memory) AS StatBefore
FROM Stats
GROUP BY Stats.Server, Stats.Time, Stats.Date
HAVING (((Stats.Server)='julie1') AND ((Stats.Date)<#8/31/2000#));
STATQ2 is:
SELECT Stats.Server, Stats.Time, Avg(Stats.Memory) AS StatAfter
FROM Stats
GROUP BY Stats.Server, Stats.Time, Stats.Date
HAVING (((Stats.Server)='julie1') AND ((Stats.Date)>#8/31/2000#));
[sig][/sig]