Thanks guys. Does any of this change for Windows though? I don't
believe I can use cat or | in the command prompt. I've also tried some
of those structures already and there seems to be a problem with my
file paths: C:\name\name\file.ext

I don't know if it's the colon or the slashes, but it won't work properly.

And about using .read and .import, does this mean you can't use them
on files that have semicolons in them?



On 8/23/06, Ulrich Schöbel <[EMAIL PROTECTED]> wrote:
On Wednesday 23 August 2006 21:45, John Salerno wrote:
> Hi everyone. Can someone tell me the proper syntax for running a sql
> script when starting up sqlite from the command line interface?
>
> Thanks,
> John
>
> ---------------------------------------------------------------------------
>-- To unsubscribe, send email to [EMAIL PROTECTED]
> ---------------------------------------------------------------------------
>--

cat scriptfile | sqlite3 mydb

or

sqlite3 -init scriptfile mydb

or

sqlite3 mydb < scriptfile

or (for a single sql command)

sqlite3 mydb 'sqlcmd'

Kind regards

Ulrich

-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------



-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------

Reply via email to