Re: Performance of count(*) and aggregate functions
I have a similar problem with federated tables when attempting to select a million rows from a federated table. The query runs out of memory on large result sets.
The Missing Manual suggests using a federated table to a view on the server to perform aggregate functions (http://www.oreillynet.com/pub/a/databases/2006/08/10/mysql-federated-tables.html?page=5)
CREATE VIEW tkey_count AS SELECT COUNT(*) AS how_many FROM tkey;
create table tkey_count_fed
(how_many int)
ENGINE=FEDERATED
CONNECTION='mysql://server2usr:datacharmer@127.0.0.1:5001/test/tkey_count';
Subject
Views
Written By
Posted
12102
April 19, 2006 05:54AM
Re: Performance of count(*) and aggregate functions
7447
October 26, 2006 05:13PM
8517
February 22, 2007 11:52AM
6042
November 21, 2008 07:24PM
5559
May 05, 2008 01:22AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.