Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

phpMyAdmin error after change column name #1054 - Unknown column 'xxx' in 'order clause'

Tags:

phpmyadmin

I recently changed a column name in a MySQL table using phpMyAdmin from customer_count to customer_viewed.

I can successfully query the new field/table through my application however I get the following error message when I click browse on the table in phpMyAdmin:

#1054 - Unknown column 'customer_count' in 'order clause'

It is as if within phpMyAdmin has this default order by customer_count stored somewhere.

I cleared everything from phpMyAdmin -> pma_table_uiprefs but still no joy.

Note: When I change the column name back to customer_count, the browse displays successfully.

Is there somewhere else in phpMyAdmin that a cached/default setting could be hiding?


I just tried the above in Firefox and it works fine, so obviously the issue has something to do with Chrome. Apologies as my questing is no longer a programming one but something to do with the browser.

like image 340
Stephen Croft Avatar asked Jan 19 '15 22:01

Stephen Croft


2 Answers

Deleting the phpMyAdmin-related Cookies should do the trick.

Open Developer Tools, press F12, go to the resources-tab, then Cookies and manually delete all the Cookies like "pma..." and "phpMyAdmin" by marking each and hitting DEL oder BackSpace. You will have to relogin to phpMyAdmin after that.

like image 158
faqoverflow Avatar answered Jan 03 '23 13:01

faqoverflow


I have found the right place, where phpmyadmin stores information about columns.

This is the database "phpmyadmin".

  1. The table "pma__column_info". Go to search and search the table name you need. Then change the field contents.
  2. Table "pma__table_uiprefs" - the same operation.
  3. Clear cookies, browser cache
  4. Reload browser.

Thats all.

like image 40
Дмитрий Белкин Avatar answered Jan 03 '23 15:01

Дмитрий Белкин