Solved

Firebird ISQL, can I prompt user to pass variable to script

Posted on 2008-10-08
4
1,086 Views
Last Modified: 2013-12-09
I need to create a batch file that runs an sql query and prompts the user to enter in variables. Its really the simplest of queries.

update invoice set departmentid=1 where invoiceno=@uservariable

it should loop until the user presses esc or something like that, is it possible?

0
Comment
Question by:lagg2007
  • 2
  • 2
4 Comments
 
LVL 19

Accepted Solution

by:
NickUpson earned 250 total points
ID: 22671530
not in isql solely, I could do it with a unix shell script so it probably can be done in a dos shell

the code would be something like

prompt for invno
while invno != 0
  isql <params>
    update invoice ...
    commit;
    exit;
prompt for invno

looping outside of the isql itself


0
 

Author Comment

by:lagg2007
ID: 22676444
Sounds like it could be what im looking for, but ive not a clue how to call that in a dos script, could you give me a hand?
0
 
LVL 19

Expert Comment

by:NickUpson
ID: 22676692
sorry, dos scripting not my area, now if you were using a proper operating system, say linux, :)
0
 

Author Comment

by:lagg2007
ID: 22677294
Thanks for help mate! i know ifs and buts. The software isnt supported on linux:(
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
SQL Server 2008 R2 - stored prodecure with execution plan make faster 24 125
Update in Sql 7 38
How do uses indexes to maximize MySQL Searches 14 55
.lee file containing data 5 42
This article describes some very basic things about SQL Server filegroups.
Read about achieving the basic levels of HRIS security in the workplace.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

860 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question