国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 數據庫 > MySQL > 正文

mysql 控制臺程序的提示符 prompt 字符串設置

2020-01-19 00:06:14
字體:
來源:轉載
供稿:網友
The prompt command reconfigures the default mysql> prompt. The string for defining the prompt can contain the following special sequences.

mysql 控制臺程序的默認提示符為 "mysql>". 該提示符可用根據需要進行修改設置:

有以下幾種設置方式:

設置shell 的環境變量 : MYSQL_PS1

shell> export MYSQL_PS1="(/u@/h) [/d]> "

使用程序啟動命令選項 : --prompt

shell> mysql --prompt="(/u@/h) [/d]> "
(user@host) [database]>

設置選項文件中的 [mysql] 節,添加 prompt 選項

[mysql]
prompt=(//u@//h) [//d]>//_
在 mysql 程序中使用 prompt (/R) 命令

mysql> prompt (/u@/h) [/d]>/_
PROMPT set to '(/u@/h) [/d]>/_'
(user@host) [database]>
(user@host) [database]> prompt
Returning to default PROMPT of mysql>
mysql>

prompt 中一些特殊的轉義字符串

OptionDescription
/cA counter that increments for each statement you issue
/DThe full current date
/dThe default database
/hThe server host
/lThe current delimiter (new in 5.1.12)
/mMinutes of the current time
/nA newline character
/OThe current month in three-letter format (Jan, Feb, …)
/oThe current month in numeric format
/Pam/pm
/pThe current TCP/IP port or socket file
/RThe current time, in 24-hour military time (0 主站蜘蛛池模板: 民权县| 衡东县| 哈密市| 澄城县| 黄龙县| 神池县| 安阳县| 山丹县| 江都市| 松潘县| 若尔盖县| 碌曲县| 宜君县| 扶沟县| 福安市| 轮台县| 巫溪县| 抚远县| 云南省| 横峰县| 云林县| 平湖市| 玉环县| 普定县| 通海县| 内乡县| 深圳市| 拉萨市| 松滋市| 连城县| 华亭县| 闵行区| 凌源市| 延寿县| 竹北市| 尚义县| 潞城市| 尚志市| 晋中市| 柳江县| 南川市|