#168 Data not shown in overview

3.2.2
closed-fixed
Jakub Vrána
Common (150)
5
2011-07-11
2011-07-08
PunchyRascal
No

When selecting data, and AJAX is used, some table cells are not shown, see screenshot.

SQL to reproduce this:

-- Adminer 3.2.2 MySQL dump

SET NAMES utf8;
SET foreign_key_checks = 0;
SET time_zone = 'SYSTEM';
SET sql_mode = 'NO_AUTO_VALUE_ON_ZERO';

DROP TABLE IF EXISTS `test`;
CREATE TABLE `test` (
`id` int(11) NOT NULL auto_increment,
`mode` int(11) NOT NULL default '0',
`group_id` int(11) NOT NULL default '0',
`table_id` int(11) NOT NULL,
`item_id` int(11) default NULL,
`item_alias` text NOT NULL,
`user_id` int(11) NOT NULL,
`data` mediumtext NOT NULL,
`create` timestamp NULL default NULL,
`update` timestamp NOT NULL default CURRENT_TIMESTAMP,
`access` timestamp NULL default NULL,
`locked` int(1) NOT NULL default '0',
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=25 DEFAULT CHARSET=utf8;

INSERT INTO `test` (`id`, `mode`, `group_id`, `table_id`, `item_id`, `item_alias`, `user_id`, `data`, `create`, `update`, `access`, `locked`) VALUES
(11, 1, 11, 354, 0, '', 3, 'O:22:\"Object\":23:{s:38:\"\0Object', '2011-07-08 10:27:19', '2011-07-08 10:27:19', '2011-07-08 10:39:31', 0);

Discussion

  • PunchyRascal
    PunchyRascal
    2011-07-08

    screenshot of the problem

     
    Attachments
  • PunchyRascal
    PunchyRascal
    2011-07-08

    The data causing the problem are serialized objects in PHP. To reproduce this, run the SQL attached and click Select in table overview. If AJAX is used, data won't show (even any further rown won't show), otherwise (e.g. opening the link in new tab) works fine.

     
  • PunchyRascal
    PunchyRascal
    2011-07-08

    SQL to reproduce

     
    Attachments
  • PunchyRascal
    PunchyRascal
    2011-07-08

    Also, when Selecting the data with no javascript (or in new tab), the text limit for the text columns (in this case mediumtext) don't work.

     
  • Jakub Vrána
    Jakub Vrána
    2011-07-11

    • status: open --> closed-accepted
     
  • Jakub Vrána
    Jakub Vrána
    2011-07-11

    First of all, you shouldn't store binary data (containing the null byte) to a text column. Use blob instead. There is no way to display the null byte in HTML which can cause problems (I didn't reproduce it however).

    I fixed Adminer to hide the null byte in HTML.

     
  • Jakub Vrána
    Jakub Vrána
    2011-07-11

    • status: closed-accepted --> closed-fixed
     
  • Jakub Vrána
    Jakub Vrána
    2011-07-11

    Thank you for the report, I've fixed it in Git. You can download the "Current development version" from http://www.adminer.org/#download