MySQLワークベンチから連携が出来た

                                                      • -

2014年2月7日(金)
ワークベンチからサーバーへ接続して、昨日に簡単に作成したテーブルの操作をしてみている。
簡単なコマンドは実行出来た。
show database;
show tables from test;
select * from kabu2;

▼しかし、delete コマンドがエラー!
Error Code: 1175. You are using safe update mode and you tried to update a table without a WHERE that uses a KEY column To disable safe mode, toggle the option in Preferences -> SQL Queries and reconnect.
→さらに前と同じ内容でinsertをしたところ正常に処理されてしまい、同じレコードが二つ出来た。
つまりprimary key となっていないから。
コマンドラインでdeleteを行うと処理された(where指定で同じ値の2件とも削除された)
→ワークベンチで、primary key を alter tables の add で実行。その後にはレコードinsert、そしてそれをdeleteの処理は今度は正常に処理される。(keyになってれば良さそうか)



▼export機能があるので試してみるが、?はてな




▼Options File をクリックしてみたところ、エラー!
Configuration file '%ProgramData%\MySQL\MySQL Server 5.6\my.ini' can not be found. New file will be created when changes are applied.

?変だな、my.iniファイルはあるはず。サーバーへのコネクションが出来なかったからをれを変更して今のように出来るようになっているのに。何かすれ違っている!?

そのメッセージにOKしたら、さらに次のメッセージが!
Configuration file did not contain section [mysqld], so a new one was added.
If that is note correct, please fix the section name in the Server Instance Editor and reopen the administrator.

?これはどういことだろう?
ファイルが無いと言っていながら、こんどはセクションが無いという?