INSERT INTO `group` (
`Id` ,
`Name` ,
`TablePrefix` ,
`MangosDatabase` ,
`MangosTable` ,
`MangosTableIndex` ,
`DBCFileName` ,
`DBCColumns` ,
`WowheadName`
)
VALUES (
NULL , 'Rozhraní klienta', 'global_settings', '', '', '', '', '', ''
), (
NULL , 'Rozhraní klienta', 'glue_settings', '', '', '', '', '', ''
);

ALTER TABLE `group` ADD `LuaFileName` VARCHAR( 255 ) NOT NULL;

UPDATE `group` SET `TablePrefix` = 'global_strings',
`LuaFileName` = 'GlobalStrings' WHERE `group`.`Id` =14 LIMIT 1 ;

UPDATE `group` SET `Name` = 'Rozhraní klienta 2',
`TablePrefix` = 'glue_strings',
`LuaFileName` = 'GlueStrings' WHERE `group`.`Id` =15 LIMIT 1 ;

CREATE TABLE IF NOT EXISTS `glue_strings` (
  `ID` int(11) unsigned NOT NULL auto_increment,
  `entry` int(11) NOT NULL,
  `Language` int(11) NOT NULL default '0',
  `User` int(11) NOT NULL,
  `Complete` int(11) NOT NULL,
  `Take` int(11) NOT NULL,
  PRIMARY KEY  (`ID`),
  KEY `entry` (`entry`),
  KEY `User` (`User`),
  KEY `Take` (`Take`),
  KEY `Language` ( `Language` ),
  KEY `Complete` ( `Complete` )
) ENGINE=MyISAM  DEFAULT CHARSET=utf8;

CREATE TABLE IF NOT EXISTS `global_strings` (
  `ID` int(11) unsigned NOT NULL auto_increment,
  `entry` int(11) NOT NULL,
  `Language` int(11) NOT NULL default '0',
  `User` int(11) NOT NULL,
  `Complete` int(11) NOT NULL,
  `Take` int(11) NOT NULL,
  PRIMARY KEY  (`ID`),
  KEY `entry` (`entry`),
  KEY `User` (`User`),
  KEY `Take` (`Take`),
  KEY `Language` ( `Language` ),
  KEY `Complete` ( `Complete` )
) ENGINE=MyISAM  DEFAULT CHARSET=utf8;

ALTER TABLE `global_strings` ADD `ShortCut` TEXT NOT NULL ,
ADD `Text` TEXT NOT NULL ,
ADD `Comment` TEXT NOT NULL ;

ALTER TABLE `glue_strings` ADD `ShortCut` TEXT NOT NULL ,
ADD `Text` TEXT NOT NULL ,
ADD `Comment` TEXT NOT NULL ;

ALTER TABLE `group_item` CHANGE `DBCColumnIndex` `DBCColumnIndex` INT( 11 ) NOT NULL DEFAULT '0';

INSERT INTO `group_item` (`Id`, `Group`, `Name`, `Column`, `MangosColumn`, `AddonFileName`, `DBCColumnIndex`) VALUES (NULL, '14', 'Text', 'Text', '', '', ''), (NULL, '14', 'Komentář', 'Comment', '', '', '');

INSERT INTO `group_item` (`Id`, `Group`, `Name`, `Column`, `MangosColumn`, `AddonFileName`, `DBCColumnIndex`) VALUES (NULL, '15', 'Text', 'Text', '', '', ''), (NULL, '15', 'Komentář', 'Comment', '', '', '');

INSERT INTO global_strings (SELECT ID, entry, Language, User, Complete, Take, id_text AS ShortCut, Text, "" AS Comment FROM `client`);
