Open borisbrodski opened 6 years ago
This is normal. When you connected the first time, an instance of sqlwbconsole.sh
was launched and associated with the current buffer.
After you tried to reconnect using the CtrlP
plugin, this will check if you already have a connection and not spawn another one. It will use the same and just do WbConnect
. So it's normal not to see the new profiles.
If you want to avoid restarting VIM, you need to also do (before CtrlP
) SWSqlBufferDisconnect
in the current sql buffer. This will terminate the current sqlwbconsole.sh
instance and then when you do CtrlP
again, it will spawn a new sqlwbconsole.sh
process which will see the new profiles.
Thank you for the hint. But may be you could also issue SWSqlBufferDisconnect
automatically, if a new connection is requested out of the already connected buffer...
This is not a good idea. When you do CtrlP
is normal and ok to re-use the existing instance. It is much more expensive to re-start the whole instance.
Is the same principle as with the GUI. You won't be re-starting the GUI
every time when you need to change the connection.
This being said, I can implement an option for whoever wishes to spawn a new instance of sqlwbconsole.sh
from CtrlP
which by default will be set to false.
Reproduction:
Result buffer:
In
.cache/sql-workbench/tmp/GVIM-__6__
:After restarting VIM everything works as expected.