Search notes:

SQL Server: sqlcmd - colon commands

:connect <server>
Edit the last sql statement. Compare with SQL*Plus' edit command. Apparently, the editor can be configured by setting sqlcmdeditor:
set sqlcmdeditor=notepad
:ed
:error
:exit
:help
:list
:listvar
Compare with :setvar
:on error
:out file.txt
:perftrace
:quit
:r file.sql
:reset
:setvar var value
Compare with :listvar
:xml on
:!!

See also

sqlcmd

Index