[mythtv-users] phpmyadmin no unique on settings table?

Hika van den Hoven hikavdh at gmail.com
Thu Jul 2 18:01:48 UTC 2015


Hoi Dan,

Thursday, July 2, 2015, 7:19:13 PM, you wrote:

> On 7/2/15 11:56 AM, Hika van den Hoven wrote:
>> Hoi Dan,
>>
>> Thursday, July 2, 2015, 2:49:11 PM, you wrote:
>>
>>> On 7/1/15 10:39 PM, Hika van den Hoven wrote:
>>>> Hoi Steven,
>>>>
>>>> Thursday, July 2, 2015, 4:23:27 AM, you wrote:
>>>>
>>>>> just got a new system running with an old database and when I go to
>>>>> the settings table in phpmyadmin I now get this error,
>>>>> "This table does not contain a unique column. Grid edit, checkbox,
>>>>> Edit, Copy and Delete features are not available."
>>>>> and am unable to edit any of the entries.
>>>>> did I do something wrong in my import? or was this table always this
>>>>> way, and if so, is there a way to fix this without affecting mythtv?
>>>>> can I just add a new column to make it the unique column?
>>>> The settings table has no index, so is not easily editable in
>>>> phpmyadmin. Probably you got phpmyadmin complaining about a lack of
>>>> prime index.
>>> Mine has a primary key, and the table should according to
>>> libs/libmythtv/dbcheck.cpp:
>>> "CREATE TABLE settings ("
>>> "  `value` varchar(128) NOT NULL DEFAULT '',"
>>> "  `data` varchar(16000) NOT NULL DEFAULT '',"
>>> "  hostname varchar(64) DEFAULT NULL,"
>>> "  KEY `value` (`value`,hostname)"
>>> ") ENGINE=MyISAM DEFAULT CHARSET=utf8;",
>>> I suggest the OP add it, as operating without one will surely be slower.
>>> _______________________________________________
>> It's just an Index not a key. A Key does not allow duplicates, so
>> unusable
> Huh? In SQL the line:

>    KEY `value` (`value`,hostname)"

> means it's the primary key, not merely an index. An index would use the
> keyword INDEX.

> _______________________________________________

Then you have a problem! It must be an index not a key. If it is a key
you kan not have the same value for different hosts!



Tot mails,
  Hika                            mailto:hikavdh at gmail.com

"Zonder hoop kun je niet leven
Zonder leven is er geen hoop
Het eeuwige dilemma
Zeker als je hoop moet vernietigen om te kunnen overleven!"

De lerende Mens



More information about the mythtv-users mailing list