vBulletin Search Engine Optimization
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| All the time I'm working with DB2 I feel that DB2 authers just hate their customers and users of their products... The last example - I want to create a stored procedure in the script, use it to add data to database inside this script and then drop this procedure. And I want this script be able to run as a script and also just copied to Command Editor. But it is impossible! You just cannot change statement termination char by something like UPDATE COMMAND OPTIONS -t @! Statement termination char can be defined only before the whole script execution - either in db2 -td @ or in spetial options of the editor you are using. What a hell... I hope I'm wrong. Does anybody know how to solve it? |
| |||
| bespridannik@gmail.com wrote: > You just cannot change statement termination char by something like > UPDATE COMMAND OPTIONS -t @! Statement termination char can be defined > only before the whole script execution - either in db2 -td @ or in > spetial options of the editor you are using. What a hell... > > I hope I'm wrong. Does anybody know how to solve it? --#SET TERMINATOR @ I will contact the ID folks.... Cheers Serge -- Serge Rielau DB2 Solutions Development IBM Toronto Lab |
| |||
| Serge Rielau wrote: > bespridannik@gmail.com wrote: >> You just cannot change statement termination char by something like >> UPDATE COMMAND OPTIONS -t @! Statement termination char can be defined >> only before the whole script execution - either in db2 -td @ or in >> spetial options of the editor you are using. What a hell... >> >> I hope I'm wrong. Does anybody know how to solve it? > --#SET TERMINATOR @ http://publib.boulder.ibm.com/infoce...c/r0010410.htm -- Serge Rielau DB2 Solutions Development IBM Toronto Lab |
| |||
| On Feb 28, 2:50*am, Serge Rielau <srie...@ca.ibm.com> wrote: > Serge Rielau wrote: > > bespridan...@gmail.com wrote: > >> You just cannot change statement termination char by something like > >> UPDATE COMMAND OPTIONS -t @! Statement termination char can be defined > >> only before the whole script execution - either in db2 -td @ or in > >> spetial options of the editor you are using. What a hell... > > >> I hope I'm wrong. Does anybody know how to solve it? > > --#SET TERMINATOR @ > > http://publib.boulder.ibm.com/infoce...ic/com.ibm.db2.... Thank you for help! And it works in DB2 CLP also as in Command Editor! Example: Next commands can be executed in DB2 CLP also as in Command Editor: --#SET TERMINATOR ; select count(*) from user; select count(*) from user; --#SET TERMINATOR % select count(*) from user% select count(*) from user% --#SET TERMINATOR ; select count(*) from user; select count(*) from user; > -- > Serge Rielau > DB2 Solutions Development > IBM Toronto Lab |
| ||||
| Bespridannik wrote: > On Feb 28, 2:50 am, Serge Rielau <srie...@ca.ibm.com> wrote: >> Serge Rielau wrote: >>> bespridan...@gmail.com wrote: >>>> You just cannot change statement termination char by something like >>>> UPDATE COMMAND OPTIONS -t @! Statement termination char can be defined >>>> only before the whole script execution - either in db2 -td @ or in >>>> spetial options of the editor you are using. What a hell... >>>> I hope I'm wrong. Does anybody know how to solve it? >>> --#SET TERMINATOR @ >> http://publib.boulder.ibm.com/infoce...ic/com.ibm.db2.... > And it works in DB2 CLP also as in Command Editor! I admit I wasn't sure about the command editor ;-) -- Serge Rielau DB2 Solutions Development IBM Toronto Lab |
| Thread Tools | |
| Display Modes | |
|
|