MySQLの履歴

基本構文

SELECT * from enquete where id =3;
UPDATE [テーブル名] SET [カラム名] = 'hoge';
INSERT INTO [テーブル名] ([カラム名]) values ('hoge');";
DELETE FROM [テーブル名] WHERE [条件];

dumpデータインポート


mysql -uroot -p -D DB名 < dumpdata.dump

phpMyAdminの文字コード設定


my.iniの設定

[client]
default-character-set=utf8

[mysql]
default-character-set=utf8

[mysqld]
default-character-set=utf8
character-set-server = utf8
skip-character-set-client-handshake
collation-server = utf8_general_ci
init-connect = SET NAMES utf8

[mysqldump]
default-character-set = utf8

起動

/etc/init.d/mysqld start

停止

/etc/init.d/mysqld stop

自動起動

chkconfig mysqld on