小男孩‘自慰网亚洲一区二区,亚洲一级在线播放毛片,亚洲中文字幕av每天更新,黄aⅴ永久免费无码,91成人午夜在线精品,色网站免费在线观看,亚洲欧洲wwwww在线观看

分享

mysql命令行,多行命令時(shí)如何取消/返回修改前邊的命令

 云中凌 2014-11-28

mysql命令行中執(zhí)行多行命令時(shí),如果前邊輸入的命令發(fā)生錯(cuò)誤,是無法返回修改的,但是可以通過輸入\c來取消前邊的輸入,但是這時(shí)如果前邊輸入的東西很多,直接取消又很可惜的話,可以通過\p來打印出前邊的命令,復(fù)制下來去修改,然后輸入\c取消來重新輸入命令。

Example
1
2
3
4
5
6
7
8
9
10
11
12
13
mysql> select 8 from a
    -> where 1=1
    ->  and 1=0
    -> \p
#輸入\p后,打印出了前邊的命令。
--------------
select 8 from a
where 1=1
 and 1=0
--------------
#依然進(jìn)入->狀態(tài),等待輸入,輸入\c,取消當(dāng)前輸入。
    -> \c
mysql>

下表列出了各個(gè)提示符并簡述它們所表示的mysql的狀態(tài):

提示符 含義
mysql> 準(zhǔn)備好接受新命令。
-> 等待多行命令的下一行。
‘> 等待下一行,等待以單引號(hào)(“’”)開始的字符串的結(jié)束。
“> 等待下一行,等待以雙引號(hào)(“””)開始的字符串的結(jié)束。
`> 等待下一行,等待以反斜點(diǎn)(‘`’)開始的識(shí)別符的結(jié)束。
/*> 等待下一行,等待以/*開始的注釋的結(jié)束。

mysql help列表

         (\?) Synonym for `help'.
clear     (\c) Clear the current input statement.
connect   (\r) Reconnect to the server. Optional arguments are db and host.
delimiter (\d) Set statement delimiter.
ego       (\G) Send command to mysql server, display result vertically.
exit      (\q) Exit mysql. Same as quit.
go        (\g) Send command to mysql server.
help      (\h) Display this help.
notee     (\t) Don't write into outfile.
print     (\p) Print current command.
prompt    (\R) Change your mysql prompt.
quit      (\q) Quit mysql.
rehash    (\#) Rebuild completion hash.
source    (\.) Execute an SQL script file. Takes a file name as an argument.
status    (\s) Get status information from the server.
tee       (\T) Set outfile [to_outfile]. Append everything into given outfile.
use       (\u) Use another database. Takes database name as argument.
charset   (\C) Switch to another charset. Might be needed for processing binlog
with multi-byte charsets.
warnings  (\W) Show warnings after every statement.
nowarning (\w) Don't show warnings after every statement.

    本站是提供個(gè)人知識(shí)管理的網(wǎng)絡(luò)存儲(chǔ)空間,所有內(nèi)容均由用戶發(fā)布,不代表本站觀點(diǎn)。請注意甄別內(nèi)容中的聯(lián)系方式、誘導(dǎo)購買等信息,謹(jǐn)防詐騙。如發(fā)現(xiàn)有害或侵權(quán)內(nèi)容,請點(diǎn)擊一鍵舉報(bào)。
    轉(zhuǎn)藏 分享 獻(xiàn)花(0

    0條評論

    發(fā)表

    請遵守用戶 評論公約

    類似文章 更多