Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

#4471 (ok 4.2.6) Undefined index warning with referenced column.

4.2.4
fixed
None
1
2014-07-18
2014-06-22
Chirayu Chiripal
No

Steps to reproduce:

  • Go to sakila > actor table.
  • Click in structure tab.
  • Click on 'change' link of 'actor_id' column.
  • Click on any other tab such as Browse tab.
  • An undefined index warning message at the bottom of the resulting page.

    Notice in ./libraries/relation.lib.php#1603
    Undefined index: actor_id
    
    Backtrace
    
    ./libraries/tbl_columns_definition_form.inc.php#137: PMA_checkChildForeignReferences(
    string 'sakila',
    string 'actor',
    string 'actor_id',
    )
    ./libraries/structure.lib.php#2309: include(./libraries/tbl_columns_definition_form.inc.php)
    ./tbl_structure.php#45: PMA_displayHtmlForColumnChange(
    string 'sakila',
    string 'actor',
    NULL,
    string 'tbl_structure.php',
    )
    

This happens for columns which are referenced by some other table. For e.g.

  • sakila > address > address_id
  • sakila > category > category_id

Discussion

  • Hi,
    Did you really get this error on a 4.2.x please?
    I couldn't reproduce it on QA_4_2, only on master.

    I'll wait for your answer to send a patch.
    Thanks.

     
  • Hi,
    Yes I can reproduce it on QA_4_2, STABLE and master branch.
    Thanks.

     
  • Perfect!
    Thanks.

     
  • Marc Delisle
    Marc Delisle
    2014-06-28

    • assigned_to: Hugues Peccatte
     
    • summary: Undefined index warning with referenced column. --> (ok 4.2.6) Undefined index warning with referenced column.
    • status: open --> resolved
    • Priority: 5 --> 1
     
  • Marc Delisle
    Marc Delisle
    2014-07-18

    • Status: resolved --> fixed