× 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.



Frank,

ALWNULL(*USRCTL) gives you the possibility to use the %NULL bif.

I could not use that option, because my programmes run in batch and can accept 
any kind of prepared SQL statement.

It is more a problem with the compilation, not the well-honoured and all-loved 
precompiler (which appears to be older than RPG II).

Regards,
Carel Teijgeler.


*********** REPLY SEPARATOR  ***********

On 13-2-03 at 10:29 Frank.Kolmann@revlon.com wrote:

>Thanks Carel,
>I already have ALWNULL(*USRCTL) in the header.
>Is this different to ALWNULL(*YES)?
>But this is a SQLRPGLE  so I suspect it could be a
>problem with the <...censored..> SQL precompiler.
>
>I am posting this to the rpg400-l list maybe
>someone there knows what to do.  This worked ok
>on V4R4 and the dumps started on V5R1.
>
>more info.
>The program used 2 loops with SQL cursors.
>The first loop processed order header records.
>The second loop processed order detail records.
>The first header and details processed OK.
>The next header was 'FETCHED' and then the program
>dumped. I fetch into a DS with an associated array
>for NULL indicators.
>I get SQLCOD of -911.
>
>This incidently is a poor way of coding for SQL errors
>It like using a golbal MONMSG CPF0000, you never know
>when something fails.
>
>0115.00 D MSA_HEAR        S              5I 0 DIM(13)
>*
>c                   DOW       @LOOP = @LOOP
>C/EXEC SQL
>C+ fetch IH into :HEA_DS :MSA_HEAR
>C/END-EXEC
>C                   If        SQLCOD <> 0
>C                   LEAVE
>C                   endif
>
>Should I raise an APAR if so how?
>Thanks again for any reply.
>Frank Kolmann
>
>PS.  I ripped out the <--censored--> SQL code
>and replaced with SETLL READ loops and program
>works just fine.
>
>
>*********** REPLY SEPARATOR  ***********
>from: "Carel Teijgeler" <coteijgeler@chello.nl>
>subject: Re: Strange SQL dumps
>
>Frank,
>
>I received those errors too, when using the QSQPRCED API. The query will
>not run. After recompiling the PGM with ALLWNULL(*YES) the PGM runs without
>failure.
>
>So my guess is null values.
>
>Regards,
>Carel Teijgeler
>
>*********** REPLY SEPARATOR  ***********
>
>On 12-2-03 at 12:38 Frank.Kolmann@revlon.com wrote:
>
>>I checked the archives and IBMs APARS but connot find anything.
>>
>>We are on V5R1 and are getting dumps from SQL.
>>
>>Does anyone know what it means or any suggestion on what to do.
>>
>>Thanks for any help,
>>Frank Kolmann
>>
>>This is the SQL DUMP
>>
>>>From file . . . . . :  QTEMP/QAP0ZDMP            Member  . . :
>QP0Z945654
>>Record format . . . . . :  QAP0ZD
>>Record length . . . :  512
>>To file . . . . . . :  *PRINT
>>          RCDNBR  *...+... 1 ...+... 2 ...+... 3 ...+... 4 ...+... 5 ...
>>+... 6 ...+... 7 ...+... 8 ...+... 9 ...+...
>>1  User Trace Dump for job 945654/SSA/MSSDAYEND. Size: 300K, Wrapped 0
>>times.
>>2
>>3  --- 02/11/2003 23:33:55 ---
>>4     0000007A:862592 SQ Run Time Dump of SQLCA section:
>>5     0000007A:877192 CCEA88F70E:02D750 L:0008 EyeCatch:
>>6     0000007A:877312  CCEA88F70E:02D750  E2D8D3C3 C1404040
>>*SQLCA   ........*
>>7     0000007A:877376 CCEA88F70E:02D758 L:0004 Length of SQLCA:
>>8     0000007A:877456  CCEA88F70E:02D750                    00000088
>>*...........h....*
>>9     0000007A:877520 CCEA88F70E:02D75C L:0004 SQL return code:
>>10     0000007A:877608  CCEA88F70E:02D750
>>FFFFFC7B     *...............#*
>>11     0000007A:877664 CCEA88F70E:02D760 L:0048 SQL error message:
>>12     0000007A:877816  CCEA88F70E:02D760  000BD4C3 C8F3F4F0 F2000004
>>B7000000     *..MCH3402.......*
>>13     0000007A:877936  CCEA88F70E:02D770  00000000 00000000 00000000
>>00000000     *................*
>>14     0000007A:878072  CCEA88F70E:02D780  00000000 00000000 00000000
>>00000000     *................*
>>15     0000007A:878192  CCEA88F70E:02D790  00000000 00000000 00000000
>>00000000     *................*
>>16     0000007A:878272  CCEA88F70E:02D7A0  00000000 00000000
>>*................*
>>17     0000007A:878336 CCEA88F70E:02D7A8 L:0008 Program name:
>>18     0000007A:878424  CCEA88F70E:02D7A0                    D8E2D8C6
>>C5E3C3C8     *........QSQFETCH*
>>19     0000007A:878496 CCEA88F70E:02D7B0 L:0018 Diag information:
>>20     0000007A:878624  CCEA88F70E:02D7B0  00000000 00000000 00000000
>>00000000     *................*
>>21     0000007A:878712  CCEA88F70E:02D7C0  00000000 00000000
>>*................*
>>22     0000007A:878768 CCEA88F70E:02D7C8 L:000B Warning flag:
>>23     0000007A:878856  CCEA88F70E:02D7C0                    40404040
>>40404040     *........        *
>>24     0000007A:878928  CCEA88F70E:02D7D0  404040
>>*   .............*
>>25     0000007A:878992 CCEA88F70E:02D7D3 L:0005 SQL state:
>>26     0000007A:879080  CCEA88F70E:02D7D0        F5 F8F0F0F4
>>*...58004........*
>>27
>> 27 records copied to member or label *N in file QSYSPRT in library QSYS.
>0
>>records excluded.
>>
>MCH3402    Escape                  40    11/02/03     23:33:54   QSQROUTE
>QSYS        *STMT    QSQROUTE     QSYS         *STMT
>                          From module . . . . . . . . :     QSQFETCH
>                          From procedure  . . . . . . :     F_NULLMAPB
>                          Statement . . . . . . . . . :   10414
>                          To module . . . . . . . . . :     QSQFETCH
>                          To procedure  . . . . . . . :     F_NULLMAPB
>                          Statement . . . . . . . . . :   10414
>Message  : Tried to refer to all or part of an object that no longer
>exists.
>Cause  . : The most common cause is that a stored address to an
>           object is no longer correct because that object was deleted or
>           part of the object was deleted.
>CPC7301    Completion              00    11/02/03   23:33:56   QDDCPF
>QSYS        0528     QC2SYS       QSYS         *STMT
>                         To module . . . . . . . . . :   QC2SYS
>                         To procedure  . . . . . . . :   system
>                         Statement . . . . . . . . . :   6
>Message . . . . :   File QAP0ZDMP created in library QTEMP.
>CPC7305    Completion              00    11/02/03   23:33:56   QDDCPFM
>QSYS        005B     QC2SYS       QSYS         *STMT
>                         To module . . . . . . . . . :   QC2SYS
>>
>
>
>_______________________________________________
>This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
>To post a message email: RPG400-L@midrange.com
>To subscribe, unsubscribe, or change list options,
>visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
>or email: RPG400-L-request@midrange.com
>Before posting, please take a moment to review the archives
>at http://archive.midrange.com/rpg400-l.





As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

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.