dbcli / mssql-cli

A command-line client for SQL Server with auto-completion and syntax highlighting
BSD 3-Clause "New" or "Revised" License
1.35k stars 191 forks source link

Switching db with `use` does not update db name in prompt #483

Open kstarzyk opened 4 years ago

kstarzyk commented 4 years ago

I experience similar issue to #408

  1. Connect to host
    $ mssql-cli -U <user> -P <password> -S <host>
    master >
  2. Switching to different DB
    master> use test_db;
    Time: 0.252s
    Commands completed successfully.
    master>
  3. Promp indicates "previous" db but context uses "new" db (\lt for instance returns tables from test_db);

If I start mssql-cli with -d flag it seems fine:

$ mssql-cli  -U <user> -P <password> -S <host> -d test_db
test_db>

However use command still does not change prompt name

Version 1.0.0