Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#373 (ok 2.11.0-rc2) Incorrect export with specified MySQL port

closed-fixed
Marc Delisle
1
2014-09-14
2007-08-03
Damien
No

When I export a table, the header of the sql file is:

-- phpMyAdmin SQL Dump
-- version 2.11.0-rc1
-- http://www.phpmyadmin.net
--
-- Host: localhost
:3307
-- Generation Time: Aug 03, 2007 at 10:49 AM
-- Server version: 5.0.45
-- PHP Version: 5.2.3
...

when I import this file, I have an error with the line of the mysql port (:3307). It seems the return char is a bug.

Discussion

  • Jürgen Wind
    Jürgen Wind
    2007-08-03

    Logged In: YES
    user_id=1383652
    Originator: NO

    thank you for reporting, since I'm using nonstandard ports as well
    I created a patch for libraries/export/sql.php:

    --- sql.php (revision 10548)
    +++ sql.php (working copy)
    @@ -195,13 +195,10 @@
    $head = PMA_exportComment('phpMyAdmin SQL Dump')
    . PMA_exportComment('version ' . PMA_VERSION)
    . PMA_exportComment('http://www.phpmyadmin.net')
    - . PMA_exportComment()
    - . PMA_exportComment($GLOBALS['strHost'] . ': ' . $cfg['Server']['host']);
    - if (!empty($cfg['Server']['port'])) {
    - $head .= ':' . $cfg['Server']['port'];
    - }
    - $head .= $crlf
    - . PMA_exportComment($GLOBALS['strGenTime'] . ': ' . PMA_localisedDate())
    + . PMA_exportComment();
    + $head .= empty($cfg['Server']['port']) ? PMA_exportComment($GLOBALS['strHost'] . ': ' . $cfg['Server']['host'])
    + : PMA_exportComment($GLOBALS['strHost'] . ': ' . $cfg['Server']['host'] . ':' . $cfg['Server']['port']);
    + $head .= PMA_exportComment($GLOBALS['strGenTime'] . ': ' . PMA_localisedDate())
    . PMA_exportComment($GLOBALS['strServerVersion'] . ': ' . substr(PMA_MYSQL_INT_VERSION, 0, 1) . '.' . (int) substr(PMA_MYSQL_INT_VERSION, 1, 2) . '.' . (int) substr(PMA_MYSQL_INT_VERSION, 3))
    . PMA_exportComment($GLOBALS['strPHPVersion'] . ': ' . phpversion());

     
  • Damien
    Damien
    2007-08-05

    • milestone: 743557 --> 744348
     
  • Marc Delisle
    Marc Delisle
    2007-08-11

    • milestone: 744348 -->
    • labels: 546627 --> Data Export
     
  • Marc Delisle
    Marc Delisle
    2007-08-11

    • priority: 5 --> 1
    • assigned_to: nobody --> lem9
    • summary: import fail when the mysql port is different --> (ok 2.11.0-rc2) Incorrect export with specified MySQL port
    • status: open --> open-fixed
     
  • Marc Delisle
    Marc Delisle
    2007-08-11

    Logged In: YES
    user_id=210714
    Originator: NO

    merged, thanks.

     
  • Marc Delisle
    Marc Delisle
    2007-08-21

    • status: open-fixed --> closed-fixed