views:

827

answers:

1

Is there any way I can run Sybase SQL commands from command prompt. I need to write a batch file which runs an SQL query on machine as a fix for a bug.

+1  A: 

Use ISQL. See http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.help.ase%5F15.0.utility/html/utility/utility10.htm for the complete reference.

Specifically, you're looking for commands like this:

ISQL -S server -D database -U user -P password

This will launch ISQL with the indicated settings, and from there you can run SQL statements against the database.

David Andres
i have isql.jar coming with SQL Anywhere 9. Is that the one? where can I get isql.exe?
Ajay
I believe that it's a part of the Adaptive Server installation.
David Andres