LoginSignup
4
6

More than 5 years have passed since last update.

【Rails】よく使うMYSQLコマンド

Posted at

Railsで開発をする際によく使用するmysqlのコマンドをまとめました。

パスワードを指定してログインする

mysql -u root -p PASSWORD;

データベースを確認する

show databases;

使用するデータベースを指定する

use databases;

テーブルを確認する

show tables;

テーブル内のデータを確認する

select * from table_name;

テーブル内のカラムを確認

destribute table_name;
4
6
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
4
6