![]() |
![]() |
![]()
Post
#1
|
|
Grupa: Zarejestrowani Postów: 2 Pomógł: 0 Dołączył: 25.01.2008 Ostrzeżenie: (0%) ![]() ![]() |
Witam serdecznie, mam problem z poniższym zapytaniem, baza jest dla forum internetowego na silniku phpbb3 i stoi na serwerze gdzie obsługiwany jest MySql w wersji 4.0
Próbowałem dokonać takiej aktualizacji i niestety po wykonaniu tego kodu: ALTER TABLE phpbb_attachments MODIFY attach_id mediumint(8) UNSIGNED NOT NULL auto_increment, MODIFY post_msg_id mediumint(8) UNSIGNED DEFAULT '0' NOT NULL, MODIFY topic_id mediumint(8) UNSIGNED DEFAULT '0' NOT NULL, MODIFY in_message tinyint(1) UNSIGNED DEFAULT '0' NOT NULL, MODIFY poster_id mediumint(8) UNSIGNED DEFAULT '0' NOT NULL, MODIFY is_orphan tinyint(1) UNSIGNED DEFAULT '1' NOT NULL, MODIFY physical_filename varchar(255) DEFAULT '' NOT NULL, MODIFY real_filename varchar(255) DEFAULT '' NOT NULL, MODIFY download_count mediumint(8) UNSIGNED DEFAULT '0' NOT NULL, MODIFY attach_comment text NOT NULL, MODIFY extension varchar(100) DEFAULT '' NOT NULL, MODIFY mimetype varchar(100) DEFAULT '' NOT NULL, MODIFY filesize int(20) UNSIGNED DEFAULT '0' NOT NULL, MODIFY filetime int(11) UNSIGNED DEFAULT '0' NOT NULL, MODIFY thumbnail tinyint(1) UNSIGNED DEFAULT '0' NOT NULL, DEFAULT CHARSET=utf8; pojawi mi się błąd: #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 'DEFAULT CHARSET=utf8' at line 18 Czy ktoś wie co można z tym zrobić? Z góry serdecznie dziękuje za pomoc |
|
|
![]() |
![]()
Post
#2
|
|
![]() Grupa: Moderatorzy Postów: 36 557 Pomógł: 6315 Dołączył: 27.12.2004 ![]() |
http://dev.mysql.com/doc/refman/5.0/en/alter-table.html
Cytat If you want to change the table default character set and all character columns (CHAR, VARCHAR, TEXT) to a new character set, use a statement like this:
ALTER TABLE tbl_name CONVERT TO CHARACTER SET charset_name; -------------------- "Myśl, myśl, myśl..." - Kubuś Puchatek || "Manual, manual, manual..." - Kubuś Programista "Szukaj, szukaj, szukaj..." - Kubuś Odkrywca || "Debuguj, debuguj, debuguj..." - Kubuś Developer |
|
|
![]()
Post
#3
|
|
Grupa: Zarejestrowani Postów: 2 Pomógł: 0 Dołączył: 25.01.2008 Ostrzeżenie: (0%) ![]() ![]() |
wykonałem zapytanie:
ALTER TABLE phpbb_attachments CONVERT TO CHARACTER SET utf8; pojawił się znowu kurcze błąd: MySQL zwrócił komunikat: ![]() #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 'CONVERT TO CHARACTER SET utf8' at line 1 Z tego co zauważyłem na stronce to jest to odnośnik do MySql 5.0, a na serwerze mam MySql 4.0 to może mieć znaczenie? |
|
|
![]() ![]() |
![]() |
Aktualny czas: 22.08.2025 - 09:20 |