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



Hi,

Here are the prototypes, data structures and call statements. The last call
(RtvDtaQ200) is failing. I am not sure if it is the 2nd parameter. I have
tried with 16MB, 15MB, %size(RtvDtaQDS) and %len(RtvDtaQDS), but fails for
all of them on V7R1.

*Prototype for QMHRDQM*-
D RtvDtaQ200 Pr ExtPgm('QMHRDQM')
D RcvVar Like(RtvDtaQDS) Options(*VarSize)
D RcvVarLen 10I 0 Const
D Format 8A Const
D QualDtaqNm 20A
D MsgSelInf Like(MsgSel200DS) Options(*VarSize)
D MsgSelInfLen 10I 0 Const
D MsgSelFmt 8A Const
D ErrCode Like(ApiErrDS) Options(*varsize)

*Data Structure for receiving parms of QMHRDQM API*-
D RtvDtaQDS DS Qualified Based(uheadPtr)
D BytesReturned 10I 0
D BytesAvl 10I 0
D MsgRtnCount 10I 0
D MsgAvlCount 10I 0
D KeyLenRtn 10I 0
D KeyLenAvl 10I 0
D MsgTxtLenReq 10I 0
D MsgTxtLenAvl 10I 0
D EntLenRtn 10I 0
D EntLenAvl 10I 0
D OffsetToEntry 10I 0
D DtaqLib 10A

*Data Structure for receiving Error code parm for APIs*
D ApiErrDS DS Qualified
D BytesProvided 10I 0
D BytesReturned 10I 0
D ErrMsgId 7A
D ReservedSpace 1A
D MsgReplaceVal 112A

*Data Structure for receiving Message Selection Info in RDQS0100 format
*D MsgSel100DS DS Qualified
D Selection 1A Inz('A')
D Reserved 3A
D MsgByteRtv 10I 0 Inz

*Data Structure for receiving Message Selection Info in RDQS0200 format*
D MsgSel200DS DS Qualified
D Selection 1A Inz('K')
D KeyOrder 2A
D Reserved 1A
D MsgByteRtv 10I 0 Inz
D KeyByteRtv 10I 0 Inz
D KeyLen 10I 0 Inz
D KeyDta 256A

*Data Structure for receiving Data Queue Description in RDQS0100 format*-
D RtvDtaQDDS DS Qualified Inz
D BytesReturned 10I 0
D BytesAvlbl 10I 0
D MsgLen 10I 0
D KeyLen 10I 0
D Sequence 1A
D SenderID 1A
D ForceInd 1A
D TextDesc 50A
D LocalOrDDM 1A
D AutoReclaim 1A
D Reserved 1A
D MsgCount 10I 0
D EntryCount 10I 0
D DtaqNm 10A
D DtaqLib 10A
D MaxEntAlw 10I 0
D InitEnt 10I 0
D MaxtEntSpec 10I 0


*The calls-*
CallP CrtUsrSpc(Wk_UserSpaceNm : ' ' : 16776704 : x'00' : '*ALL' :
'Data Queue Dump' : '*YES' : ApiErrDS);

CallP RtvDtaQD(RtvDtaQDDS : %size(RtvDtaQDDS) : 'RDQD0100' :
Ent_QualDtaQ);

CallP RtvPtrUsrSpc(Wk_UserSpaceNm : uHeadPtr : ApiErrDS);

CallP RtvDtaQ200(RtvDtaQDS : 15728128 : 'RDQM0200' :
Ent_QualDtaQ : MsgSel200DS :
(16 + RtvDtaQDDS.KeyLen) : 'RDQS0200'
: ApiErrDS);




On Thu, Aug 22, 2013 at 12:34 PM, Michael Ryan <michaelrtr@xxxxxxxxx> wrote:

Especially check for the use of binary fields in the call. I'm too lazy
(err, busy) to look up the definition, but I got bit by an old API usage
where there were binary fields. Had to switch to INT.


On Thu, Aug 22, 2013 at 12:21 PM, Jon Paris <jon.paris@xxxxxxxxxxxxxx
wrote:

Please show us the API call (and proto if used) plus any structures being
used etc.

It is possible that you have a scenario in which corruption has always
been taking place (possibly due to incorrect API usage) but changes in
the
compiler in V7 mean that you are now corrupting something that matters.


On 2013-08-22, at 11:09 AM, Shubhadeep Roy <shubhadeep.roy@xxxxxxxxx>
wrote:

Hi,

I wrote a utility to retrieve messages from a data queue and store them
in
an SQL table using API QMHRDQM. The utility works fine at V5R4 but is
failing in V7R1 with the following error. Could this just be a
compilation
issue?

Additional Message
Information


Message ID . . . . . . : MCH0601 Severity . . . . . . . :
40
Message type . . . . . :
Escape
Date sent . . . . . . : 08/22/13 Time sent . . . . . . :
11:06:56


Message . . . . : Space offset X'00000000' or X'0000000000EFFDFF' is
outside
current limit for object QPADEV000MSROY2
208748.
Cause . . . . . : A program tried to set a space pointer, tried to
use
storage outside a space, or tried to use an unallocated page in
teraspace.
The space class is X'07'. The space class designates the type of
space:
00-primary associated space (includes space
objects).
01-secondary associated space
0.
02-implicit process space for automatic
storage.
03-implicit process space for static storage in activation group
mark

X'0000000000000000'.

04-implicit process space for heap identifier X'00000000' in
activation
group mark
X'0000000000000000'.
05-constant
space.
06-space for handle-based heap identifier
X'00000000'.
07-teraspace offset
X'0000000000EFFDFF'.
08-teraspace for System i5 PASE memory address
X'0000000000EFFDFF'.
Offset X'00000000' only applies to storage outside
teraspace.
X'80000000000000000000000000EFFDFF' is a pointer to the teraspace
page
or
the start of the implicit process space for the
allocation.



--

Warm regards,
Shubhadeep Roy
All is well. Everything will be OK!!! - Shubh
--
This is the RPG programming on the IBM i (AS/400 and iSeries)
(RPG400-L)
mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.


Jon Paris

www.partner400.com
www.SystemiDeveloper.com




--
This is the RPG programming on the IBM i (AS/400 and iSeries) (RPG400-L)
mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.


--
This is the RPG programming on the IBM i (AS/400 and iSeries) (RPG400-L)
mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
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 ...

Follow-Ups:
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.