Re: Is Temporary table right approach
Thanks for your comments. I just gave him a sample value. On Fri, Apr 17, 2009 at 11:10 PM, Andrew Braithwaite < andrew.braithwa...@lovefilm.com> wrote: > >> If you can not eliminate your temporary tables, you have to adjust > the > following parameters in my.cnf [mysqld] > >>max_heap_table_size=1G > >>tmp_table_size=1G > > You're making a lot of assumptions about this guy's setup. You > shouldn't just tell > him to apply these kinds of settings as you don't what effect they will > have on his > system. If he only has 512MB available for MySQL and he starts writing > lots of > 1GB temporary tables what's going to happen to the performance of his > server? > > With advice like that you could grind his server/s to a halt and cause > his site > To die a miserable swappy death. > > Andrew > > -Original Message- > From: Moon's Father [mailto:yueliangdao0...@gmail.com] > Sent: 17 April 2009 06:36 > To: Manoj Singh > Cc: php...@lists.php.net; mysql@lists.mysql.com > Subject: Re: Is Temporary table right approach > > If you can not eliminate your temporary tables, you have to adjust the > following parameters in my.cnf > [mysqld] > max_heap_table_size=1G > tmp_table_size=1G > > On Fri, Apr 17, 2009 at 12:57 PM, Manoj Singh > wrote: > > > Hi All, > > > > Thanks for your valuable input. > > > > I have decided to use temporary table approach. Since I am using it > for the > > first time and this has to be done in the production server. Do I need > to > > consider some facts before using this such as setting some parameters > in > > my.cnf etc or the MYSQL will handle all. Actually I want to know if > any one > > has faces issues practically when implementing temporary tables. > > > > Waiting for your suggestion. > > > > Thanks, > > Manoj > > > > > > On Fri, Apr 17, 2009 at 8:21 AM, Moon's Father > wrote: > > > >> Use temporary table can be a good idea. But I think you performance > would > >> be boost so much if you can do something else to replace the > temporary > >> table. > >> On Wed, Apr 15, 2009 at 2:03 PM, Manoj Singh > wrote: > >> > >>> Hi All, > >>> > >>> I have a query which returns the large number of ids which i am > using in > >>> other queries. I am doing this in PHP. Now the first query can > return > >>> unlimited number of ids which might create problem in PHP. I want to > >>> store > >>> this ids in MYSQL through temporary table so that i can access that > ids > >>> in > >>> other queries directly. > >>> > >>> Do you think the approach is right or there is any other good > approach? > >>> > >>> Please suggest. > >>> > >>> Regards, > >>> Manoj > >>> > >> > >> > >> > >> -- > >> I'm a MySQL DBA in china. > >> More about me just visit here: > >> http://yueliangdao0608.cublog.cn > >> > > > > > > > -- > I'm a MySQL DBA in china. > More about me just visit here: > http://yueliangdao0608.cublog.cn > -- David Yeung, MySQL Senior Support Engineer, Sun Gold Partner. My Blog:http://yueliangdao0608.cublog.cn Comanpy: http://www.actionsky.com
RE: Is Temporary table right approach
>> If you can not eliminate your temporary tables, you have to adjust the following parameters in my.cnf [mysqld] >>max_heap_table_size=1G >>tmp_table_size=1G You're making a lot of assumptions about this guy's setup. You shouldn't just tell him to apply these kinds of settings as you don't what effect they will have on his system. If he only has 512MB available for MySQL and he starts writing lots of 1GB temporary tables what's going to happen to the performance of his server? With advice like that you could grind his server/s to a halt and cause his site To die a miserable swappy death. Andrew -Original Message- From: Moon's Father [mailto:yueliangdao0...@gmail.com] Sent: 17 April 2009 06:36 To: Manoj Singh Cc: php...@lists.php.net; mysql@lists.mysql.com Subject: Re: Is Temporary table right approach If you can not eliminate your temporary tables, you have to adjust the following parameters in my.cnf [mysqld] max_heap_table_size=1G tmp_table_size=1G On Fri, Apr 17, 2009 at 12:57 PM, Manoj Singh wrote: > Hi All, > > Thanks for your valuable input. > > I have decided to use temporary table approach. Since I am using it for the > first time and this has to be done in the production server. Do I need to > consider some facts before using this such as setting some parameters in > my.cnf etc or the MYSQL will handle all. Actually I want to know if any one > has faces issues practically when implementing temporary tables. > > Waiting for your suggestion. > > Thanks, > Manoj > > > On Fri, Apr 17, 2009 at 8:21 AM, Moon's Father wrote: > >> Use temporary table can be a good idea. But I think you performance would >> be boost so much if you can do something else to replace the temporary >> table. >> On Wed, Apr 15, 2009 at 2:03 PM, Manoj Singh wrote: >> >>> Hi All, >>> >>> I have a query which returns the large number of ids which i am using in >>> other queries. I am doing this in PHP. Now the first query can return >>> unlimited number of ids which might create problem in PHP. I want to >>> store >>> this ids in MYSQL through temporary table so that i can access that ids >>> in >>> other queries directly. >>> >>> Do you think the approach is right or there is any other good approach? >>> >>> Please suggest. >>> >>> Regards, >>> Manoj >>> >> >> >> >> -- >> I'm a MySQL DBA in china. >> More about me just visit here: >> http://yueliangdao0608.cublog.cn >> > > -- I'm a MySQL DBA in china. More about me just visit here: http://yueliangdao0608.cublog.cn -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/mysql?unsub=arch...@jab.org
Re: Is Temporary table right approach
If you can not eliminate your temporary tables, you have to adjust the following parameters in my.cnf [mysqld] max_heap_table_size=1G tmp_table_size=1G On Fri, Apr 17, 2009 at 12:57 PM, Manoj Singh wrote: > Hi All, > > Thanks for your valuable input. > > I have decided to use temporary table approach. Since I am using it for the > first time and this has to be done in the production server. Do I need to > consider some facts before using this such as setting some parameters in > my.cnf etc or the MYSQL will handle all. Actually I want to know if any one > has faces issues practically when implementing temporary tables. > > Waiting for your suggestion. > > Thanks, > Manoj > > > On Fri, Apr 17, 2009 at 8:21 AM, Moon's Father > wrote: > >> Use temporary table can be a good idea. But I think you performance would >> be boost so much if you can do something else to replace the temporary >> table. >> On Wed, Apr 15, 2009 at 2:03 PM, Manoj Singh >> wrote: >> >>> Hi All, >>> >>> I have a query which returns the large number of ids which i am using in >>> other queries. I am doing this in PHP. Now the first query can return >>> unlimited number of ids which might create problem in PHP. I want to >>> store >>> this ids in MYSQL through temporary table so that i can access that ids >>> in >>> other queries directly. >>> >>> Do you think the approach is right or there is any other good approach? >>> >>> Please suggest. >>> >>> Regards, >>> Manoj >>> >> >> >> >> -- >> I'm a MySQL DBA in china. >> More about me just visit here: >> http://yueliangdao0608.cublog.cn >> > > -- I'm a MySQL DBA in china. More about me just visit here: http://yueliangdao0608.cublog.cn
Re: Is Temporary table right approach
Hi All, Thanks for your valuable input. I have decided to use temporary table approach. Since I am using it for the first time and this has to be done in the production server. Do I need to consider some facts before using this such as setting some parameters in my.cnf etc or the MYSQL will handle all. Actually I want to know if any one has faces issues practically when implementing temporary tables. Waiting for your suggestion. Thanks, Manoj On Fri, Apr 17, 2009 at 8:21 AM, Moon's Father wrote: > Use temporary table can be a good idea. But I think you performance would > be boost so much if you can do something else to replace the temporary > table. > On Wed, Apr 15, 2009 at 2:03 PM, Manoj Singh wrote: > >> Hi All, >> >> I have a query which returns the large number of ids which i am using in >> other queries. I am doing this in PHP. Now the first query can return >> unlimited number of ids which might create problem in PHP. I want to store >> this ids in MYSQL through temporary table so that i can access that ids in >> other queries directly. >> >> Do you think the approach is right or there is any other good approach? >> >> Please suggest. >> >> Regards, >> Manoj >> > > > > -- > I'm a MySQL DBA in china. > More about me just visit here: > http://yueliangdao0608.cublog.cn >
Re: Is Temporary table right approach
Use temporary table can be a good idea. But I think you performance would be boost so much if you can do something else to replace the temporary table. On Wed, Apr 15, 2009 at 2:03 PM, Manoj Singh wrote: > Hi All, > > I have a query which returns the large number of ids which i am using in > other queries. I am doing this in PHP. Now the first query can return > unlimited number of ids which might create problem in PHP. I want to store > this ids in MYSQL through temporary table so that i can access that ids in > other queries directly. > > Do you think the approach is right or there is any other good approach? > > Please suggest. > > Regards, > Manoj > -- I'm a MySQL DBA in china. More about me just visit here: http://yueliangdao0608.cublog.cn