Re: Copia e ripristino DB

Inviato da Metalslug il 19/4/2012 1:35:03
Mi rendo conto che sto cercando di fare qualcosa che non è adatto alle mie capacità...

Leggendo la discussione qui su XI mi è venuta la brillante idea di convertire i database da latin1 a utf8.

La conversione sembra funzionare, tranne in alcune tabelle che al momento dell importazione mi da i seguenti messaggi:

QueryCREATE TABLE xxxx_PDdownloads_indexpage indeximage varchar(255) DEFAULT 'blank.png' NOT NULLindexheading varchar(255) DEFAULT 'PD-Downloads' NOT NULLindexheader longtext NOT NULLindexfooter longtext NOT NULLnohtml tinyint(8) DEFAULT '1' NOT NULLnosmiley tinyint(8) DEFAULT '1' NOT NULLnoxcodes tinyint(8) DEFAULT '1' NOT NULLnoimages tinyint(8) DEFAULT '1' NOT NULLnobreak tinyint(4) DEFAULT '0' NOT NULLindexheaderalign varchar(25) DEFAULT 'left' NOT NULLindexfooteralign varchar(25) DEFAULT 'center' NOT NULLKEY indexheading (indexheading), KEY indexheader (indexheader), KEY indexfooter (indexfooter) );

MySQLBLOB/TEXT column 'indexheader' used in key specification without a key


Mentre la tabella è cosi composta:

# Backup for MySQL
#
# --------------------------------------------------------

#
# Table structure for table xxxx_PDdownloads_indexpage
#

DROP TABLE IF EXISTS xxxx_PDdownloads_indexpage;
CREATE TABLE xxxx_PDdownloads_indexpage (
   
indeximage varchar(255) DEFAULT 'blank.png' NOT NULL,
   
indexheading varchar(255) DEFAULT 'PD-Downloads' NOT NULL,
   
indexheader longtext NOT NULL,
   
indexfooter longtext NOT NULL,
   
nohtml tinyint(8) DEFAULT '1' NOT NULL,
   
nosmiley tinyint(8) DEFAULT '1' NOT NULL,
   
noxcodes tinyint(8) DEFAULT '1' NOT NULL,
   
noimages tinyint(8) DEFAULT '1' NOT NULL,
   
nobreak tinyint(4) DEFAULT '0' NOT NULL,
   
indexheaderalign varchar(25) DEFAULT 'left' NOT NULL,
   
indexfooteralign varchar(25) DEFAULT 'center' NOT NULL,
   
KEY indexheading (indexheading),
   
KEY indexheader (indexheader),
   
KEY indexfooter (indexfooter)
);

#
# Dumping data for table xxxx_PDdownloads_indexpage
#

INSERT INTO xxxx_PDdownloads_indexpage VALUES ('logo-en.gif'''''''00001'left ''left');


Cosa c è di sbagliato che non conosco?
E' un problema di importazione o la conversione in utf8 dovrebbe cambiare altro?

Questo post è stato a partire da: http://www.xoopsitalia.org/modules/newbb/p-69947/re-copia-e-ripristino-db.html