/    Sign up×
Community /Pin to ProfileBookmark

Query Timeout

Is there a way for me to speed up a query? I have a table that is called payment which have about 10k lines. It times out before the query is done. I have used set_time_limit (120) but that takes way to long. Should I make tables for each indivial person, etc? What can I do please?

to post a comment
PHP

2 Comments(s)

Copy linkTweet thisAlerts:
@NogDogAug 09.2006 — Probably most important: make sure you create indexes on any columns which are used in the WHERE clause of your query.

Otherwise, without knowing what DBMS you are using, what sort of query you're trying to do, etc., there's not much else to say.
Copy linkTweet thisAlerts:
@bokehAug 09.2006 — My guess is something else is wrong. I just did a test on a table I have with 77,000 lines and it took 240 milliseconds. Are you running this on an Atari.
×

Success!

Help @cfultz51 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.6,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,

tipper: @Samric24,
tipped: article
amount: 1000 SATS,
)...