Od dłuższego czasu już męcze się z importem bazy danych - gdy importuje baze zapisaną w kodowaniu domyślnym [wstyd, ale nie wiem jakie to] to wyrzuca błędy w stylu:
Kod
Błąd
zapytanie SQL:
INSERT INTO phpbb_search_wordlist( word_text, word_id, word_common )
VALUES (
'b�dzie', '23 ', '0 ');
MySQL zwrócił komunikat: Dokumentacja
#1062 - Duplicate entry 'b' for key 1
zapytanie SQL:
INSERT INTO phpbb_search_wordlist( word_text, word_id, word_common )
VALUES (
'b�dzie', '23 ', '0 ');
MySQL zwrócił komunikat: Dokumentacja
#1062 - Duplicate entry 'b' for key 1
natomiast jeśli zapiszę baze w UTF-8 wywala:
Kod
#
# phpBB Backup Script
# Dump of tables for b9_259080_phpbb2
#
# DATE : 04-01-2007 17:31:23 GMT
#
#
# TABLE: phpbb_auth_access
#
DROP TABLE IF EXISTS phpbb_auth_access;
MySQL zwrócił komunikat: Dokumentacja
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ďťżDROP TABLE IF EXISTS phpbb_auth_access' at line 1
# phpBB Backup Script
# Dump of tables for b9_259080_phpbb2
#
# DATE : 04-01-2007 17:31:23 GMT
#
#
# TABLE: phpbb_auth_access
#
DROP TABLE IF EXISTS phpbb_auth_access;
MySQL zwrócił komunikat: Dokumentacja
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ďťżDROP TABLE IF EXISTS phpbb_auth_access' at line 1
a gdy skasuje ten pierwszy wpis .. :
Kod
Błąd
zapytanie SQL:
#
# phpBB Backup Script
# Dump of tables for b9_259080_phpbb2
#
# DATE : 04-01-2007 17:31:23 GMT
#
#
# TABLE: phpbb_auth_access
#
CREATE TABLE phpbb_auth_access(
group_id mediumint( 8 ) NOT NULL ,
forum_id smallint( 5 ) unsigned NOT NULL ,
auth_view tinyint( 1 ) NOT NULL ,
auth_read tinyint( 1 ) NOT NULL ,
auth_post tinyint( 1 ) NOT NULL ,
auth_reply tinyint( 1 ) NOT NULL ,
auth_edit tinyint( 1 ) NOT NULL ,
auth_delete tinyint( 1 ) NOT NULL ,
auth_sticky tinyint( 1 ) NOT NULL ,
auth_announce tinyint( 1 ) NOT NULL ,
auth_vote tinyint( 1 ) NOT NULL ,
auth_pollcreate tinyint( 1 ) NOT NULL ,
auth_attachments tinyint( 1 ) NOT NULL ,
auth_mod tinyint( 1 ) NOT NULL ,
KEY group_id( group_id ) ,
KEY forum_id( forum_id )
);
MySQL zwrócił komunikat: Dokumentacja
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ďťż
CREATE TABLE phpbb_auth_access(
group_id mediumint(8) NOT NULL,
forum_id s' at line 1
zapytanie SQL:
#
# phpBB Backup Script
# Dump of tables for b9_259080_phpbb2
#
# DATE : 04-01-2007 17:31:23 GMT
#
#
# TABLE: phpbb_auth_access
#
CREATE TABLE phpbb_auth_access(
group_id mediumint( 8 ) NOT NULL ,
forum_id smallint( 5 ) unsigned NOT NULL ,
auth_view tinyint( 1 ) NOT NULL ,
auth_read tinyint( 1 ) NOT NULL ,
auth_post tinyint( 1 ) NOT NULL ,
auth_reply tinyint( 1 ) NOT NULL ,
auth_edit tinyint( 1 ) NOT NULL ,
auth_delete tinyint( 1 ) NOT NULL ,
auth_sticky tinyint( 1 ) NOT NULL ,
auth_announce tinyint( 1 ) NOT NULL ,
auth_vote tinyint( 1 ) NOT NULL ,
auth_pollcreate tinyint( 1 ) NOT NULL ,
auth_attachments tinyint( 1 ) NOT NULL ,
auth_mod tinyint( 1 ) NOT NULL ,
KEY group_id( group_id ) ,
KEY forum_id( forum_id )
);
MySQL zwrócił komunikat: Dokumentacja
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ďťż
CREATE TABLE phpbb_auth_access(
group_id mediumint(8) NOT NULL,
forum_id s' at line 1
i tak dalej, ciągle jakiś błąd, jak uporam się z jednym to wywala następny.
Macie jakies pomysły? Byłbym wdzięczny za każdą odpowiedź.