Home » RDBMS Server » Performance Tuning » how to improve (mysql, 5.0, XP)
how to improve [message #363064] Fri, 05 December 2008 00:18 Go to next message
daredavil82
Messages: 1
Registered: December 2008
Location: ALASKA
Junior Member
any one here have idea how to improve this query execution time?

select tEzai.c_tEzai_orgid as orgid, 
       tEzai.c_tEzai_tktype as tokenid, 
       tokentext as tokentype,
       count(distinct c_tEzai_sno) as total,
       count(distinct c_tEztkbind_sno) as consumed, 
       (count(distinct c_tEzai_sno) - count(distinct c_tEztkbind_sno)) as free 
from tokentext LEFT JOIN tEzai ON tokenid = c_tEzai_tktype 
               LEFT JOIN tEztkbind ON tokenid = c_tEztkbind_tktype 
where c_tEzai_orgid = 1 and c_tEztkbind_orgid = 1 
group by tokentext order by tokenid;


Re: how to improve [message #363075 is a reply to message #363064] Fri, 05 December 2008 00:55 Go to previous messageGo to next message
Michel Cadot
Messages: 64133
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Are you sure the query even compiles?

Don't you mind to post useful information like:
- statistics
- indexes
- explain plan
-....

Regards
Michel
Re: how to improve [message #363089 is a reply to message #363075] Fri, 05 December 2008 01:22 Go to previous messageGo to next message
tahpush
Messages: 961
Registered: August 2006
Location: Stockholm/Sweden
Senior Member

Confused by the topic

Quote:
how to improve (mysql, 5.0, XP)


Confused
Re: how to improve [message #363106 is a reply to message #363089] Fri, 05 December 2008 02:20 Go to previous message
Michel Cadot
Messages: 64133
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Doh! Didn't see it.
Of course, this is an Oracle forum and we don't answer MySQL question.
Are you working on Oracle or MySQL?

Regards
Michel

Previous Topic: Reg Reorg activity
Next Topic: Production Performance Issue
Goto Forum:
  


Current Time: Thu Dec 08 03:55:02 CST 2016

Total time taken to generate the page: 0.11072 seconds