怎么把代码提示
mysql>
替换成
本机IP@用户名>

解决方案 »

  1.   

    my.cnf的
    [mysql]选项组里加
    prompt="\\h@\\u>"  是这样?
      

  2.   

    也可以直接用MYSQL。EXE的命令 prompt \\h@\\u>
      

  3.   

    Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.mysql> prompt \h@\u>
    PROMPT set to '\h@\u>'
    localhost@foo>show databases;
    +--------------------+
    | Database           |
    +--------------------+
    | information_schema |
    | foo                |
    | test               |
    +--------------------+
    3 rows in set (0.06 sec)localhost@foo>