IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Getting RLCP abend when using substr or mod function in db2


IBM Mainframe Forums -> DB2
Post new topic   This topic is locked: you cannot edit posts or make replies.
View previous topic :: View next topic  
Author Message
sathiyendran.erulan

New User


Joined: 04 Mar 2009
Posts: 11
Location: chennai

PostPosted: Sat Sep 15, 2012 2:31 pm
Reply with quote

While performing any of the below query getting RLCP abend in CICS screen.
select count(*) into l-nbr-cnt from cust_data where cust_nbr between 100000000 and 999999999 and substr(char(cust_nbr),6,4='4907' and cust_type in (' ','0');
select count(*) into l-nbr-cnt from cust_data where cust_nbr between 100000000 and 999999999 and mod(cust_nbr,10000)=4907 and cust_type in (' ','0');

cust_nbr declared as decimal(9,0) in table and cobol equivalent used in code that PIC s9(9) comp-3.
05 l-nbr-count pic s9(4) comp-4.

Expected output is to retrieve all the cust_nbr ending with 4907.

Please advice me to resolve this abend.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Sat Sep 15, 2012 3:28 pm
Reply with quote

change l-nbr-count to PIC S9(9) COMP.

are CUST_NBR, and CUST_TYPE in an INDEX

Quote:
Expected output is to retrieve all the cust_nbr ending with 4907


well, if that is your expected output,
then change COUNT(*) to CUST_NBR

and why is this being done in CICS?

if that is the 'requirement', the 'requirment' is stupid.

actually, what you should do is:
  • unload CUST_DATA where cust_type in (' ','0')
  • use a SORT product to determine the count of each of the last 4 of CUST_NBR
  • publish the output to everybody that needs this sensitive and important piece of info
  • and then move on to more important business problems
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Sat Sep 15, 2012 4:54 pm
Reply with quote

as far as RLCP abend,
I found this while google'n
Quote:
RLCP is an ABEND code issued by the CANDLE Omegamon CICS Product indicating that
a transaction has exeeded a limit of CPU seconds
set in the OMEGANON Global parameters
for the CICS addresspace being monitored. It can be overridden. Consult OMRGAMON documentation.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Sun Sep 16, 2012 2:50 am
Reply with quote

Hello,

You found some reason to post this same question again?

You were given the same hint about the cause of the RLCP (from me) with confirmation from another member in the original topic.

All this did was to show inconsideration and waste several people's time.

This duplicate is being locked. Maybe TS will now implement properly (in batch).
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   This topic is locked: you cannot edit posts or make replies. View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts ISAM and abend S03B JCL & VSAM 10
No new posts Calling an Open C library function in... CICS 1
No new posts DATE2 function SYNCSORT 15
No new posts Help on PL/I jsonPutValue function PL/I & Assembler 8
No new posts how to use Tso outtrap external function All Other Mainframe Topics 8
Search our Forums:

Back to Top