Subject RE: [firebird-support] Re: Import data from flat files
Author Oleg Lebedev
Putting sql in the file and running it won't work for me. The reason is
that I wanted to save myself some time and write a shell script that
would, say drop multiple tables (this is a very simple example). So, I
would have an array of table names I need to drop and a loop that goes
through all of them and sends a line "DROP TABLE $t_name" to isql.

-----Original Message-----
From: Fabrice Aeschbacher [mailto:fabrice.aeschbacher@...]
Sent: Wednesday, October 01, 2003 2:39 AM
Subject: [firebird-support] Re: Import data from flat files
Importance: Low

--- In, Oleg Lebedev <oleg.lebedev@w.
..> wrote:
> Ok, great.
> I am wondering if there is a way to execute an SQL command through
> FB utiltity from a shell. Smth like:
> bash> time isql -c "SELECT count(*) FROM tableA" /tmp/mydb.fdb
> *************************************


Put your SQL command into a command.sql file. This file must start

CONNECT 'host:/path/to/database.fdb'
PASSWORD 'masterkey';

Then try running isql with "-i" option:

$isql host:/path/to/database.fdb -u SYSDBA -p masterkey -o isql.out -m
-e -i command.sql


To unsubscribe from this group, send an email to:

Your use of Yahoo! Groups is subject to


This e-mail may contain privileged or confidential material intended for the named recipient only.
If you are not the named recipient, delete this message and all attachments.
Unauthorized reviewing, copying, printing, disclosing, or otherwise using information in this e-mail is prohibited.
We reserve the right to monitor e-mail sent through our network.