Bug #37030 | Can't find a Falcon TableSpace if no Falcon Tables are using that TableSpace. | ||
---|---|---|---|
Submitted: | 28 May 2008 9:37 | Modified: | 11 Jun 2008 18:42 |
Reporter: | Santo Leto | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server: Falcon storage engine | Severity: | S3 (Non-critical) |
Version: | 6.0.4-alpha, 6.0-falcon bk | OS: | Any |
Assigned to: | CPU Architecture: | Any | |
Tags: | falcon tablespaces |
[28 May 2008 9:37]
Santo Leto
[28 May 2008 21:28]
Hakan Küçükyılmaz
Verified as described with latest Falcon sources: 6.0.6-alpha-debug [23:28] root@test>CREATE TABLESPACE `falcon_tablespace_fr_4` ADD DATAFILE -> 'falcon_tablespace_fr_4' EXTENT_SIZE = 1M INITIAL_SIZE = 1M ENGINE = -> FALCON; Query OK, 0 rows affected (0.01 sec) [23:29] root@test>SELECT DISTINCT `tablespace` FROM -> `information_schema`.`FALCON_TABLES`; Empty set (0.00 sec) [23:29] root@test>DROP DATABASE IF EXISTS `falcon_database_fr`; Query OK, 0 rows affected, 1 warning (0.00 sec) [23:29] root@test>CREATE DATABASE IF NOT EXISTS `falcon_database_fr`; Query OK, 1 row affected (0.00 sec) [23:29] root@test>CREATE TABLE `falcon_database_fr`.`falcon_table_fr` -> TABLESPACE `falcon_tablespace_fr_4` -> ENGINE = FALCON -> IGNORE AS SELECT * FROM `mysql`.`user`; Query OK, 6 rows affected (0.02 sec) Records: 6 Duplicates: 0 Warnings: 0 [23:29] root@test>SELECT DISTINCT `tablespace` FROM -> `information_schema`.`FALCON_TABLES`; +------------------------+ | tablespace | +------------------------+ | falcon_tablespace_fr_4 | +------------------------+ 1 row in set (0.01 sec)
[4 Jun 2008 17:01]
Ann Harrison
This bug should be against the tablespace editor. The query described in the bug will never report a tablespace with no tables because there will never be a row in the TABLES table for the absence of a table. There is a TABLESPACES Information Schema table that does have the necessary information.
[4 Jun 2008 18:27]
Santo Leto
This is the good solution I was waiting for. But `information_schema`.`tablespaces` is not included in version 6.0.4-alpha (the latest version available in binary format); this is the reason because I opened the bug. In fact, in 6.0.4-alpha (if I am not mistaken, but please advice) there is no possibility to know which tablespaces have been created because the table TABLESPACES wasn't added in information_schema yet. mysql> show tables like 'table%'; +---------------------------------------+ | Tables_in_information_schema (table%) | +---------------------------------------+ | TABLES | | TABLE_CONSTRAINTS | | TABLE_PRIVILEGES | +---------------------------------------+ 3 rows in set (0.00 sec) So, to list tablespaces you are forced to select over `information_schema`.`FALCON_TABLES`. In other words, in version 6.0.4-alpha I can't find a falcon tablespace if no falcon tables are using that tablespace just because the only way to list tablespaces is executing the query SELECT DISTINCT `tablespace` FROM `information_schema`.`FALCON_TABLES`; but of course 'there will never be a row in the TABLES table for the absence of a table'. I know that the query above is wrong; I have the same problem in the 'Metadata Catalog' included in our software. And this is a serious issue because I need to find information in an easy way to create a 'Metadata Catalog'. To list tablespaces I don't want to select over the table `FALCON_TABLES` but over a 'TABLESPACES' table. If this has been fixed in 6.0.5, wow!, I will change the query executed by the 'Metadata Catalog' and by the 'TableSpace Editor' (and by the 'TableSpace List' used within the 'Create Table Wizard). So, hope to find `information_schema`.`tablespaces` in 6.0.5-alpha or 6.0.6-alpha. I will test this when I will have a chance to download that versions. Many Thanks.
[11 Jun 2008 18:42]
Kevin Lewis
Thank you for your bug report. This issue has been committed to our source repository of that product and will be incorporated into the next release. If necessary, you can access the source repository and build the latest available version, including the bug fix. More information about accessing the source trees is available at http://dev.mysql.com/doc/en/installing-source.html