使用ISQL执行脚本 [英] Executing a script using ISQL

查看:586
本文介绍了使用ISQL执行脚本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在创建一个简单的isql脚本,但是它无法正常工作,我需要一些帮助来找出问题所在.
我需要连接到数据库并执行一个SQL文件.这是我的脚本,称为script.sql:

I'm creating a simple isql script but it's not working and I need some help to find out whats wrong with it.
I need to connect to a database and execute a SQL file. This is my script called script.sql:

CONNECT 'localhost:C:\Monde\Servidor\db\monde.fdb' USER 'SYSDBA' PASSWORD 'masterkey';    
update usuario  
set senha = 'MYkWEn0kHLHHdm'  
where login = 'rose'

当我尝试使用来连接到我的数据库时:

When I try to connect to my database using.:

isql.exe -i script.sql

我收到此跟随消息.

Use CONNECT or CREATE DATABASE to specify a database
Expected end of statement, encountered EOF

推荐答案

好吧,尽管这是我发现如何解决的老问题,但您只需要添加de -q参数即可,如下所示:

Ok although it's an old question I found out how to do it, you just need to append de -q parameter, like this:

isql.exe -q -i script.sql

来源:

iSQL参考表单Destructor.de

这篇关于使用ISQL执行脚本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆