× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I'm a greenhorn,

Trying to use SQL statements in CL program to update a temp file for a
report.
Using CSSTKN3 to run SQL statements in CSSTKN4...

CSSTKN3 - Source

1.00              PGM
2.00              RUNSQLSTM  SRCFILE(R36MODS/QCLSRC) SRCMBR(CSSTKN4) +
3.00              COMMIT(*NONE)
4.00              ENDPGM


CSSTKN4 - Source

01.00              CREATE TABLE QTEMP/TBLSTKN (ITEM CHAR (20 ) NOT NULL WITH
DEFAULT,
02.00              QTY DEC (10 , 4) NOT NULL WITH DEFAULT)
03.00              INSERT INTO QTEMP/TBLSTKN SELECT IJITEM , SUM(IJQTY) FROM
CSSTKN
04.00              GROUP BY IJITEM

What looks wrong? - Table gets created but having problem with insert I
think.

DUMP attached...




Tim Ellifritz
Creative Stage Lighting Co., Inc.
149 Rt. 28N
North Creek, NY 12853
T 518-251-3302 X 218
F 518-251-2908

            Message                               Message                 From  
                       To                    
Time        ID                  Sev       Type    Text                    
Program          Inst        Program          Inst 
141225      SQL9010             30        ESC     RUNSQLSTM command faile 
QSQSCHEM         078F        CSSTKN3          000C 
                                                  d.                            
                                             
141225      CPF9999             40        ESC     Function check. SQL9010 
QMHUNMSG         0000        CSSTKN3          000C 
                                                   unmonitored by CSSTKN3       
                                             
                                                   at statement 200, inst       
                                             
                                                  ruction X'000C'.              
                                             
                                                            Variables           
                                             

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 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.