J
James B
I am doing the following query for a game stats page in
ASP and Access mdb. Is there another way I can rewrite
it to execute faster?
SELECT
GAMES.ID as GameID, GAMES.DisplayName as DisplayName,
STATS.ScoreLevel as ScoreLevel, STATS.SecPlayed as
SecPlayed, STATS.LevelNum as LevelNum, STATS.Difficulty
as Difficulty
FROM
GAMES, STATS
WHERE
GAMES.ID = STATS.GameID AND STATS.PackageCRC=328161819
ORDER BY
STATS.SecPlayed ASC, STATS.ScoreTotal DESC,
STATS.LevelNum ASC, STATS.ID;
All WHERE and ORDER BY fields are already indexed. FYI
GAMES contains about 1k records and STATS 10k.
Is it faster to join the two tables using another type of
JOIN rather than a multiple SELECT?
Also I only need the TOP X results starting at N, I tried
using the SQL TOP command for this but couldn't figure
out to control where it started at, any suggestions to do
that?
ASP and Access mdb. Is there another way I can rewrite
it to execute faster?
SELECT
GAMES.ID as GameID, GAMES.DisplayName as DisplayName,
STATS.ScoreLevel as ScoreLevel, STATS.SecPlayed as
SecPlayed, STATS.LevelNum as LevelNum, STATS.Difficulty
as Difficulty
FROM
GAMES, STATS
WHERE
GAMES.ID = STATS.GameID AND STATS.PackageCRC=328161819
ORDER BY
STATS.SecPlayed ASC, STATS.ScoreTotal DESC,
STATS.LevelNum ASC, STATS.ID;
All WHERE and ORDER BY fields are already indexed. FYI
GAMES contains about 1k records and STATS 10k.
Is it faster to join the two tables using another type of
JOIN rather than a multiple SELECT?
Also I only need the TOP X results starting at N, I tried
using the SQL TOP command for this but couldn't figure
out to control where it started at, any suggestions to do
that?