Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I tried installing phpmyadmin on Debian Squeeze with a nginx and mysql-server installed. I ran sudo apt-get install phpmyadmin, and all appeared to be going well until setup threw me this:

An error occurred while installing the database: 

mysql said: ERROR 1064 (42000) at line 72: You have an error in your SQL    
syntax; check the manual that corresponds to your MySQL server version      
for the right syntax to use near '(14) NOT NULL, `sqlquery` text NOT        
NULL, PRIMARY KEY (`id`), KEY `usernam' at line 6

...what do?

share|improve this question
Please show us the full output or at least some infos before that? – quanta Dec 15 '11 at 6:28
@quanta what do you want me to show? It asks me whether I want to do dbconfig_common, I say yes, it asks for the root password, and then it gives me that error. – jibcage Dec 15 '11 at 6:54
What is your sources.list? Paste it. Chances are your mixing repositories. – user104294 Dec 15 '11 at 22:39
The error is quite strange. apt-get clean and try again. If if didn't work, you can download the phpmyadmin source code and extract to Apache document root. – quanta Dec 16 '11 at 4:16

Replace "timestamp(14)" by "timestamp" in /usr/share/dbconfig-common/data/phpmyadmin/install/mysql (pma_history section).

Then reinstall phpmyadmin.

share|improve this answer
Editing files installed by a Debian package like this can cause a maintenance problem as your edits can be overwritten by a package update. You should divert the file to avoid this (see dpkg-divert). Can I also encourage you to file a Debian bug against the phpmyadmin package (sudo apt-get install reportbug; reportbug) as it appears to be broken. – David North Apr 1 '13 at 15:50

Reconfiguring phpmyadmin (instead of reinstalling it) after having fixed the script as suggested by Krevindiou might be good enough:

sudo dpkg-reconfigure phpmyadmin
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.