#2642 Function PMA_DBI_get_tables_full does not show all tables

2.11.4
wont-fix
Interface (555)
5
2013-06-11
2008-02-14
No

Hi !

I already asked in german forum but it seems nobody has similar problems. Since PMA 2.10 i encountered problems displaying my databases - they seems to be missing at all; only a few are displayed. So i commented out in database_interface.lib.php function PMA_DBI_get_tables_full line ~ 233 to ~ 297

if (PMA_MYSQL_INT_VERSION >= 50002) {
...
}

This helps displaying my databases. I use MySQL 5.1.22 on W32.

Discussion

1 2 > >> (Page 1 of 2)
  • Marc Delisle

    Marc Delisle - 2008-02-14
    • assigned_to: nobody --> lem9
     
  • Marc Delisle

    Marc Delisle - 2008-02-14

    Logged In: YES
    user_id=210714
    Originator: NO

    If you
    echo '(' . PMA_MYSQL_INT_VERSION . ')';

    just before this "if", what is displayed?

     
  • Thomas Brunnthaler

    Logged In: YES
    user_id=877196
    Originator: YES

    It shows 50122

     
  • Marc Delisle

    Marc Delisle - 2008-02-16

    Logged In: YES
    user_id=210714
    Originator: NO

    I have no problems here with 5.1.22 but the server is Linux.

    In the lines you commented out, the $sql variable is built with a query. Just before the PMA_DBI_fetch_result() that uses this $sql, please add
    echo $sql;
    and post the results here.

     
  • Marc Delisle

    Marc Delisle - 2008-02-16
    • status: open --> pending
     
  • Thomas Brunnthaler

    Logged In: YES
    user_id=877196
    Originator: YES

    SELECT *, `TABLE_SCHEMA` AS `Db`, `TABLE_NAME` AS `Name`, `ENGINE` AS `Engine`, `ENGINE` AS `Type`, `VERSION` AS `Version`, `ROW_FORMAT` AS `Row_format`, `TABLE_ROWS` AS `Rows`, `AVG_ROW_LENGTH` AS `Avg_row_length`, `DATA_LENGTH` AS `Data_length`, `MAX_DATA_LENGTH` AS `Max_data_length`, `INDEX_LENGTH` AS `Index_length`, `DATA_FREE` AS `Data_free`, `AUTO_INCREMENT` AS `Auto_increment`, `CREATE_TIME` AS `Create_time`, `UPDATE_TIME` AS `Update_time`, `CHECK_TIME` AS `Check_time`, `TABLE_COLLATION` AS `Collation`, `CHECKSUM` AS `Checksum`, `CREATE_OPTIONS` AS `Create_options`, `TABLE_COMMENT` AS `Comment` FROM `information_schema`.`TABLES` WHERE `TABLE_SCHEMA` IN ('Shop') LIMIT 99 OFFSET 0

     
  • Thomas Brunnthaler

    • status: pending --> open
     
  • Jürgen Wind

    Jürgen Wind - 2008-02-18

    Logged In: YES
    user_id=1383652
    Originator: NO

    SELECT *, `...
    I can't imagine that the wildcard is intentional...

     
  • Thomas Brunnthaler

    Logged In: YES
    user_id=877196
    Originator: YES

    Well here is a screenshot...
    File Added: screenshot.jpg

     
  • Thomas Brunnthaler

    Logged In: YES
    user_id=877196
    Originator: YES

    But you're right - if i correct line 261 to:

    SELECT * FROM `TABLE_SCHEMA` AS `Db`,

     
  • Marc Delisle

    Marc Delisle - 2008-02-18

    Logged In: YES
    user_id=210714
    Originator: NO

    Nope, this produces an invalid query, there is another FROM clause (FROM
    `information_schema`.`TABLES`) further in this query.

    I imagine that it fails, having the same effect as commenting it out.

    windkiel probably meant this: SELECT `TABLE_SCHEMA` AS `Db`,...
    I don't know the goal of this wildcard.

    What happens if you paste this query (with the wildcard) to the query window?

     
  • Thomas Brunnthaler

    Logged In: YES
    user_id=877196
    Originator: YES

    sql = 'SELECT TABLE_SCHEMA` AS `Db` results in not listing my databases.
    sql = 'SELECT * FROM `TABLE_SCHEMA` AS `Db` works for me but may your'e right and the error is on another place.

     
  • Marc Delisle

    Marc Delisle - 2008-02-21

    Logged In: YES
    user_id=210714
    Originator: NO

    If you take the query you posted on 2008-02-18 06:15 and run it with phpMyAdmin's query window, do you get an error message from MySQL?

     
  • Thomas Brunnthaler

    Logged In: YES
    user_id=877196
    Originator: YES

    SQL-Befehl: Dokumentation

    SELECT *
    FROM `TABLE_SCHEMA` AS `Db` , `TABLE_NAME` AS `Name` , `ENGINE` AS `Engine` , `ENGINE` AS `Type` , `VERSION` AS `Version` , `ROW_FORMAT` AS `Row_format` , `TABLE_ROWS` AS `Rows` , `AVG_ROW_LENGTH` AS `Avg_row_length` , `DATA_LENGTH` AS `Data_length` , `MAX_DATA_LENGTH` AS `Max_data_length` , `INDEX_LENGTH` AS `Index_length` , `DATA_FREE` AS `Data_free` , `AUTO_INCREMENT` AS `Auto_increment` , `CREATE_TIME` AS `Create_time` , `UPDATE_TIME` AS `Update_time` , `CHECK_TIME` AS `Check_time` , `TABLE_COLLATION` AS `Collation` , `CHECKSUM` AS `Checksum` , `CREATE_OPTIONS` AS `Create_options` , `TABLE_COMMENT` AS `Comment`
    FROM `information_schema`.`TABLES`
    WHERE `TABLE_SCHEMA`
    IN (
    'Shop'
    )
    LIMIT 99
    OFFSET 0

    MySQL meldet: Dokumentation
    #1109 - Unknown table 'table_schema' in information_schema

    So that means it has same effect commenting out the full $sql statement from line ~260 to ~ 289. If i do so, it will also show all my tables.

     
  • Jürgen Wind

    Jürgen Wind - 2008-02-22

    Logged In: YES
    user_id=1383652
    Originator: NO

    SELECT *
    FROM `TABLE_SCHEMA` AS `Db` , `TABLE_NAME` AS `Name` , `ENGINE` AS
    ---8<---
    , `CREATE_OPTIONS` AS `Create_options` , `TABLE_COMMENT` AS `Comment`
    FROM `information_schema`.`TABLES`

    this is not legal sql syntax.

     
  • Jürgen Wind

    Jürgen Wind - 2008-02-22

    Logged In: YES
    user_id=1383652
    Originator: NO

    SELECT *
    FROM `TABLE_SCHEMA` AS `Db` , `TABLE_NAME` AS `Name` , `ENGINE` AS
    ---8<---
    , `CREATE_OPTIONS` AS `Create_options` , `TABLE_COMMENT` AS `Comment`
    FROM `information_schema`.`TABLES`

    this is not legal sql syntax.

     
  • Marc Delisle

    Marc Delisle - 2008-02-22

    Logged In: YES
    user_id=210714
    Originator: NO

    And this is not the query I asked to try. I asked for:
    SELECT *, `TABLE_SCHEMA` AS `Db`, `TABLE_NAME` AS `Name`, `ENGINE` AS
    `Engine`, `ENGINE` AS `Type`, `VERSION` AS `Version`, `ROW_FORMAT` AS
    `Row_format`, `TABLE_ROWS` AS `Rows`, `AVG_ROW_LENGTH` AS `Avg_row_length`,
    `DATA_LENGTH` AS `Data_length`, `MAX_DATA_LENGTH` AS `Max_data_length`,
    `INDEX_LENGTH` AS `Index_length`, `DATA_FREE` AS `Data_free`,
    `AUTO_INCREMENT` AS `Auto_increment`, `CREATE_TIME` AS `Create_time`,
    `UPDATE_TIME` AS `Update_time`, `CHECK_TIME` AS `Check_time`,
    `TABLE_COLLATION` AS `Collation`, `CHECKSUM` AS `Checksum`,
    `CREATE_OPTIONS` AS `Create_options`, `TABLE_COMMENT` AS `Comment` FROM
    `information_schema`.`TABLES` WHERE `TABLE_SCHEMA` IN ('Shop') LIMIT 99
    OFFSET 0

     
  • Thomas Brunnthaler

    Logged In: YES
    user_id=877196
    Originator: YES

    All right sir - your query returns:

    Zeige Datensätze 0 - 29 (31 insgesamt, die Abfrage dauerte 0.1752 sek.)

     
  • Thomas Brunnthaler

    Logged In: YES
    user_id=877196
    Originator: YES

    Uhm - strange. Now it works as expected. Is it possible that information schema has been updated by quering the table once ?

     
  • Marc Delisle

    Marc Delisle - 2008-02-23

    Logged In: YES
    user_id=210714
    Originator: NO

    Well, it's not supposed to, but W32 itself can be full of surprises.

    Are you saying that your initial problem is now gone?

     
  • Thomas Brunnthaler

    Logged In: YES
    user_id=877196
    Originator: YES

    I just installed phpmyadmin rel. 2.11.5 and same problems happens again.
    I can see only the first of my 31 tables within my database. Executed the mysql statement does not help. So i assume i forgot some of my edits in database_interface.lib.
    But it happens only in one database folder, if i view eg. vbulletin i can see all tables.

     
  • Marc Delisle

    Marc Delisle - 2008-02-25

    Logged In: YES
    user_id=210714
    Originator: NO

    With 2.11.5-rc1 and your database where you are having this problem (shop?), what is the output of the SELECT statement (see 2008-02-22 15:36).

     
  • Marc Delisle

    Marc Delisle - 2008-02-25

    Logged In: YES
    user_id=210714
    Originator: NO

    By the way, MySQL 5.1.23 has been released.

     
1 2 > >> (Page 1 of 2)

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks