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



Larenzo,

You are sending this to 3 call stack entries earlier than the program that's calling QMHSNDPM.  I wonder why you picked "3"? How do you know it will always be 3, never more, and never less?

My guess is that 3 entries back is QDBPUT, and that's why you're getting this back.  Obviously, since your program is called by an IBM routine, they can choose to use any number of call stack entries, and change it whenever they want.  You'll need to troubleshoot your program to find out exactly what's going on, here... and look at the call stack at the appropriate time to see if I'm right.  But, it seems dangerous to me to "just assume" it'll always be 3 calls stack entries.

-SK


On 6/19/2018 1:03 PM, Larenzo Alexander wrote:
We recently upgraded from v7r1 to v7r3 and then my applications using QMHRCVPM to retrieve the program that cause the database to fire the trigger stop working. Any ideas why and the solution? Or if there is a better way to retrieve the program name that cause the trigger to fire? My variable is getting set to 'QDBPUT '


// ---Receive Pgm Message Format RCVM0200 data Layout---------------
D RCVM0200 DS
D RcvPgmNam 10a overlay(rcvm0200:111)
D TestNpgm 1a overlay(RcvPgmNam:2)

// ---aou error return code-----------------------------------------
D vApiErrDs DS
D vbytpv 10i 0 inz(%size(vApiErrDs))
D vbytav 10i 0 inz(0)
D vmsgid 7a
D vresvd 1a
D vrpldta 50a

// ---Send messages------------------------------------------------
D qmhsndpm PR ExtPgm('QMHSNDPM')
D 7a const
D 20a const
D 65a const
D 10i 0 const
D 10a const
D 10a const
D 10i 0 const
D 4a
Db like(vApiErrDS)

// ---Receive messages----------------------------------------------
D qmhrcvpm PR ExtPgm('QMHRCVPM')
Db like(rcvm0200)
D 10i 0 const
D 8a const
D 10a const
D 10i 0 const
D 10a const
D 4a
D 10i 0 const
D 10a const
Db like(vApiErrDS)


// ---------------------------------------------
// Get program's name that is updating the file.
// Send message to 3rd job in stack.
// Program name that replies, fired the trigger.
// ---------------------------------------------
callp QMHSNDPM(' ':'QCPFMSG QSYS ':
'Message Data':65:'*INFO ':'* ': 3:MsgKey:vApiErrDS);

callp QMHRCVPM(rcvm0200:%size(rcvm0200):'RCVM0200':'*':0:'*INFO '
MsgKey:0:'*REMOVE ':vApiErrDS);

ProcedureName1 = %proc();


// Only run for ATV Units Offline program
if RcvPgmNam = 'VIN020R';


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.