When trying Edit Table Data in MySQL Workbench 5.2.37, its in read only mode.
It is editable only if the table has a primary key.
Is there any fix to deal with table without primary key??
Thanks
As one of the suggestion I tried upgrading WB 5.2.40. But still this issue exists.. Could any one Help please..
To turn it off, you can use the SET GLOBAL statement as shown below: SET GLOBAL read_only=0; The option should now be turned off.
A table can be returned to read and write using the following command: ALTER TABLE READ WRITE; In read-only mode, the following operations are permitted on the table: Select.
You can add or modify the columns or indexes of a table, change the engine, add foreign keys, or alter the table name. To access the MySQL Table Editor, right-click a table name in the Navigator area of the sidebar with the Schemas secondary tab selected and click Alter Table.
I'm assuming the table has a primary key. First try to run a unlock tables command to see if that fixes it.
If all else fails you can alter the table to create a new primary key column with auto-increment and that should hopefully fix it. Once you're done you should be able to remove the column without any issues.
As always you want to make a backup before altering tables around. :)
Note: MySQL workbench cannot work without a primary key if that's your issue. However if you have a many to many table you can set both columns as primary keys which will let you edit the data.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With