Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Mailing Lists -> Oracle-L -> using vim as SQL*Plus editor on Windows
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
I remember a recent thread about the above topic, where the issue was that
all changed made in the editor were not reflected in the SQL buffer in
SQL*Plus. I think I know why:
if you define the _EDITOR as gvim, and you use the EDIT command from SQL*Plus, SQL*Plus first launches a DOS command box and from there the GUI vim window -- but then the DOS box is immediately closed, so SQL*Plus thinks the editing session is over. Just watch the SQL*Plus window: the "SQL>" prompt comes back, while it shouldn't -- it should wait until your editing session is over.
the solution: don't use gvim, but use "regular" vim instead:
SQL> DEFINE _EDITOR='vim -c "set filetype=sql"'
works like a charm, including nice SQL-sensitive coloring... (I am using vim6.3, oracle10g, Windows XP)
Kind regards,
Lex.