If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > spool in oracle

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 09-19-06, 22:51
welyngj welyngj is offline
Registered User
 
Join Date: Feb 2004
Posts: 15
spool in oracle

These code in oracle:
SPOOL &3
SELECT MESSAGE FROM ZUDTB03 WHERE SH_NAME = '&2' ;
SPOOL OFF
how to change to db2 code?
Thanks
Reply With Quote
  #2 (permalink)  
Old 09-20-06, 05:02
guyprzytula guyprzytula is offline
Registered User
 
Join Date: Jun 2006
Posts: 471
spool

put the sql in a file eg test.sql
execute from command line
db2 connect to xxx
db2 -tvsf test.sql > out.file
out.file will keep all results
specify -x if header and trailer are not needed
__________________
Best Regards, Guy Przytula
DB2 UDB LUW certified V6/7/8
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On