Joinutility seperatorLogin utility separator Infobright.com
   
 
It is very slow to export a query result with join sql to file
Posted: 05 October 2010 03:00 AM   Ignore ]  
Newbie
Rank
Total Posts:  1
Joined  2010-09-30

hello,
I encounter a problem when export a query result to a file using ICE:

select ... into outfile ‘a.txt’ from t1,t2 where t1.id=t2.id;

It run very slowly,but the following sql is fast:

select ... into outfile ‘a.txt’ from t1;

How I improve export performence?
Thank you.

Profile
 
Posted: 05 October 2010 04:28 AM   Ignore ]   [ # 1 ]  
Super Duper Member
Avatar
RankRankRankRankRank
Total Posts:  964
Joined  2008-08-18

Hi !

In the first case you do a join. I do not think there is any problem with export - simply the first query must do a join and it takes time.
You can post table definitions and query log (see http://www.infobright.org/wiki/Query_Execution_Log/) if you would like to ask how to speed up the join.

Profile