Joomla!, Wordpress tips for building your site

How to search table name with MySQL

Published on| December 3rd, 2009 | No Comment.

You may want to know table name in DataBase with MySQL.
If you want to do it, you should input the following command (SHOW TABLES command).

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
> mysql -h=xxx -u=username -p=**** dbname
 
Welcome to the MySQL monitor.  Commands end with ; or g.
Your MySQL connection id is 290
Server version: 5.1.36-community MySQL Community Server (GPL)
 
Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.
 
mysql> SHOW TABLES like 'wp_%';
+-----------------------+
| Tables_in_bgcom (wp_%)|
+-----------------------+
| wp2_blog_off_comments           |
| wp2_blog_off_links              |
| wp2_blog_off_options            |
| wp2_blog_off_postmeta           |
| wp2_blog_off_posts              |
| wp2_blog_off_term_relationships |
| wp2_blog_off_term_taxonomy      |
| wp2_blog_off_terms              |
| wp2_blog_off_usermeta           |
| wp2_blog_off_users              |
+-----------------------+
13 rows in set (0.01 sec)
 
mysql>

Line 1 is the login command. -h = xxx-u = username-p =**** dbname

xxx: mysql host name
username: username to login
****: password to login
dbname: database name to use

On Line 9, the table name with the character string of 'wp_' at the head is searched, and displayed.






Comments

Leave a Reply








Transrator

Recent Posts

Categories

Tag Cloud

execute remove フロントページ 投稿ページ トップページ install WIndows Note Convert META generator 日付 donwload file manage multibyte utf-8 unicode shiftjis euc console サイトマップ 問題 ParmaLink Redirect パーマリンク はみ出る pre テンプレート テーマ タグクラウド マルチランゲージ リダイレクト PHP(タグ) タグ table control HTML(タグ) コマンド 国際化(翻訳) SQLite(タグ) MySQL(タグ) qTranslate プラグイン(タグ) Wordpress(タグ)

Links

Site Description

Joomla!, Wordpress as CMS using a site building, site management, software usage to describe the development tips.

  • はてなブックマークへ追加する
  • Facebookでシェアする
  • twitter でつぶやく
  • Google Plusでシェアする
  • Pocketでシェアする
ページトップへ