Table editor doesn't show any fields - what am I missing?

[expired user #4200]'s profile image [expired user #4200] posted 15 years ago in General Permalink
Recently updated to the latest version of HeidiSQL and I am having a problem with the table editor/properties.

A simple table like:

CREATE TABLE "log" (
"Id" int(8) unsigned NOT NULL AUTO_INCREMENT,
"OrgId" int(10) unsigned DEFAULT NULL,
"Visit" int(10) unsigned DEFAULT NULL,
"TimeStamp" timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
PRIMARY KEY ("Id")
)


HeidiSQL's CREATE code is:

CREATE TABLE `log` (
PRIMARY KEY (`Id`)
)
COLLATE=latin1_swedish_ci
ENGINE=MyISAM
ROW_FORMAT=FIXED
AUTO_INCREMENT=15893
AVG_ROW_LENGTH=17



and no fields are listed in the column pane

This is not limited to this one table - it's all tables in all databases


Am I doing something wrong? do I need to clear some settings?

I have tried to revert to release version without any difference - currently using: x.y rev 2598

Thanks!
Søren
ansgar's profile image ansgar posted 15 years ago Permalink
I too have encountered this effect on several tables, sporadically spread over random databases. The reason for the editor displaying 0 columns is that the server returns a blank cell in SHOW CREATE TABLE xyz. HeidiSQL needs this result to parse it. I'm sure this is a known bug in the server and there may be a workaround for it. Probably REPAIR TABLE xyz solves the problem?
[expired user #4200]'s profile image [expired user #4200] posted 15 years ago Permalink
Thanks for the reply Anse!

Ok, have followed your lead. Ran CHECK TABLE on all tables - didn't find anything.

I then installed HeidiSQL on a different machine - same results.
Now contemplating the server as the issue I installed a new server (v5.1.34) and exported a couple of databases to it -- same results

The result of the SHOW CREATE TABLE is what you see in the first snippet.

Is there any error/process logging I can turn on in HeidiSQL?


Søren
ansgar's profile image ansgar posted 15 years ago Permalink
No error logging available, wouldn't help you much anyway. It's the server returning a blank CREATE TABLE statement in some cases. I'm still searching on bugs.mysql.com to find a relevant description.
ansgar's profile image ansgar posted 15 years ago Permalink
Ups... I just found that the mysql prompt doesn't have such a problem, when you type
mysql> SHOW CREATE TABLE xyz;
.. that works on at least one table which does not work in HeidiSQL. Logical wise this is a bug in Zeos.
ansgar's profile image ansgar posted 15 years ago Permalink
Suspicious Unicode relevance here: The mysql prompt tells me the table has a comment:
...) ENGINE=MyISAM AUTO_INCREMENT=39 DEFAULT CHARSET=utf8 COMMENT='Årsager for afvisning og tilhørende label numre'

Now, after I have altered that comment using
ALTER TABLE cm_reason COMMENT='bla';

... the table is suddenly editable in HeidiSQL!

So my theory is now: Zeos somehow truncates the content of the SHOW CREATE TABLE result if it contains critical characters.

Strange that your table definition (log) doesn't contain any critical chars.
ansgar's profile image ansgar posted 15 years ago Permalink
hardball, I have "fixed" my only broken table which didn't show columns. Would you be so nice and zip the log.frm, log.myd and log.myi file and attach it to this bug report?
ansgar's profile image ansgar posted 15 years ago Permalink
hardball, if you're interested in fixing that I recommend watching the above mentioned bug report.

Would be nice if you try to fix the table files as described in comment #3 - that solved the problem at least for me.

Please login to leave a reply, or register at first.