Re: Using ISQL with vi editor?
Posted in 1995
>From: ldeckard@databank.com (L Deckard) >Subject: Using ISQL with vi editor? >Date: Tue, 17 Jan 1995 16:56:13 LOCAL >X-Informix-List-Id: <news.10871> >I use ISQL interactively by ' isql <database_name> - '. While in the >isql interactive prompt I can invoke vi editor by ' > !vi '. Correct -- it's not documented, but you always have been able to (well, since ISQL 2.00, anyway). >I was wondering if you can create something in vi (while in isql) and when >you exit vi, send whats in the vi buffer to isql to run? No -- not at all. The escape is just an opportunity to run a command. ISQL has no idea what you've done. >Also, is there a way you can edit a SQL command you just sent to isql back >into vi? No -- not this either. >I use to do this in Sybase ISQL and would like to it in Informix. You could try poking in the c.d.i archives for a program SQLCMD which I wrote. It handles exactly this sort of thing, as well as various other improvements on the basic ISQL (non-screen-mode) command -- it was designed for use in shell scripts and does things the way you need commands to, so it doesn't vary the output format whimsically, and it can be made to stop on an error, and so on. My current version is not really stable enough to release. Yours, Jonathan Leffler (johnl@informix.com) #include <disclaimer.h>