|
Mike, In this case, you don't specify what to do with your Select statement, so the SELECT is considered invalid. In the interactive STRSQL interface, it knows it should display the resultset. In a batch environment, you have to tell SQL what you want to do with your result set, since there's no display available.... One way to do this, if you intend to save the output as a db2 file is to use the following syntax: CREATE TABLE lllll/nnnnn AS ( SELECT ... FROM ... ) WITH DATA; hth, Eric DeLong Sally Beauty Company MIS-Project Manager (BSG) 940-297-2863 or ext. 1863 -----Original Message----- From: midrange-l-bounces@xxxxxxxxxxxx [mailto:midrange-l-bounces@xxxxxxxxxxxx]On Behalf Of Mike Pantzopoulos - (H/O) Sent: Thursday, October 26, 2006 9:08 PM To: midrange-l@xxxxxxxxxxxx Subject: Differences between STRSQL and RUNSQLSTM I get the impression that there are differences in how the above two products treat SQL, but I can't find any specific documentation on what the differences might be.. The following test SQL runs correctly through STRSQL: select agtbra from (select * from anvfiles/agtmas) as x When I put this statement into a script I get the following (cut & paste): Record *...+... 1 ...+... 2 ...+... 3 ...+... 4 ...+... 5 ...+... 6 ...+... 7 . 1 select agtbra from (select * from anvfiles/agtmas) as x; * * * * * E N D O F S O U R C E * * * * * SQL0084 30 1 Position 1 SQL statement not allowed. Message Summary Total Info Warning Error Severe Terminal 1 0 0 0 1 0 30 level severity errors found in source Should I expect the two products to behave exactly the same way? Thanks ********************************************************************************************************* This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you are not the intended recipient, any use, disclosure or copying of this message is unauthorised. If you have received this message in error, please reply using the sender's email address. This footnote confirms that this email message has been scanned for computer viruses. EIG-Ansvar Limited does not accept liability for any loss or damage, whether caused by our own negligence or not, that results from a computer virus or defect in the transmission of this email or any attached file. EIG-Ansvar Limited - Australia (A.B.N. 21 007 216 506) Email : insure@xxxxxxxxxxxxxxxx Eig-Ansvar Limited - New Zealand Email : insure@xxxxxxxxxxxxxxxx *********************************************************************************************************
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.