LoginSignup
1
0

More than 3 years have passed since last update.

本番環境のMySQLをターミナルで見やすくする

Posted at

本番環境でちゃんとデータ入力出来てるかな〜って時にだいたい使うのが

select*from users

このクエリの結果表示されるデータはMySQLの要素が多いとごちゃごちゃに出てきます。

Image from Gyazo

こんな感じで。

うぉおおおん 見辛い! 見づら過ぎる!

この問題を解決したいと思います。

やり方は簡単です。

MySQLクエリの最後に \Gをつけてあげる

select*from users\G;

すると

Image from Gyazo

見やすい! Beutiful!

ということで \Gをつけてみましょう というお話でした。
(ちなみにMacでの\は option+¥です)

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0