Re: Covering Index without the data file (myisam)

2012-11-24 Thread Reindl Harald


Am 24.11.2012 22:02, schrieb Hank:
 Hello everyone,
 
  I know this is a longshot, but is there any way to eliminate the MYD
 file for a table that has a full covering index? The index is larger
 than the datafile, since it contains all the records in the datafile,
 plus a second reverse index.  It seems redundant to have to also store
 a MYD file

simple answer: NO



signature.asc
Description: OpenPGP digital signature


Re: Covering Index without the data file (myisam)

2012-11-24 Thread Eric Bergen
MyISAM can't do this but innodb can. If you change to an innodb table
and define your index as the primary key then row data is clustered
with the primary key. This means there is no additional storage
overhead for the primary key because it is just the row data. This
will break down if you define secondary indexes though because the
primary key is copied for each secondary index.

http://dev.mysql.com/doc/refman/5.0/en/innodb-index-types.html

On Sat, Nov 24, 2012 at 1:15 PM, Reindl Harald h.rei...@thelounge.net wrote:


 Am 24.11.2012 22:02, schrieb Hank:
 Hello everyone,

  I know this is a longshot, but is there any way to eliminate the MYD
 file for a table that has a full covering index? The index is larger
 than the datafile, since it contains all the records in the datafile,
 plus a second reverse index.  It seems redundant to have to also store
 a MYD file

 simple answer: NO




-- 
Eric Bergen
eric.ber...@gmail.com
http://www.ebergen.net

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql



Re: Covering Index without the data file (myisam)

2012-11-24 Thread Karen Abgarian
Hello, 

Well, you have just invented what is known as index organized tables.   The 
MyISAM engine does not implement those. 
If it did, it would have to deal with quite a few circumstances unique to IOTs. 
   One such circumstance is degradation 
of efficiency with the increase of record length, another is bloating the size 
of secondary indexes, and there is quite a few more...

In short, the alternative to keeping the MYD file would be much worse :-) 

Peace
Karen.

On 24.11.2012, at 13:02, Hank wrote:

 Hello everyone,
 
 I know this is a longshot, but is there any way to eliminate the MYD
 file for a table that has a full covering index? The index is larger
 than the datafile, since it contains all the records in the datafile,
 plus a second reverse index.  It seems redundant to have to also store
 a MYD file.
 
 Thanks,
 
 -Hank
 
 -- 
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:http://lists.mysql.com/mysql
 


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/mysql