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

Increment number for every group of records


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
srajendran2

New User


Joined: 13 May 2008
Posts: 56
Location: Chennai

PostPosted: Thu Nov 09, 2017 10:31 pm
Reply with quote

Hi,
My requirement is to increment the policy numbers within the data file for testing. every policy starts with record type 10 & ends with record type 13. All the records already have the dummy policy number 80988116.

Code:

90+20171108+15:05:51+HEADER+
10+ABCD001   +000080988116   +123
11+ABCD001   +000080988116   +123
12+ABCD001   +000080988116   +123
13+ABCD001   +000080988116   +123
10+ABCD001   +000080988116   +123
11+ABCD001   +000080988116   +123
12+ABCD001   +000080988116   +123
13+ABCD001   +000080988116   +123


I would like to add sequence number as below

Code:

90+20171108+15:05:51+HEADER+
10+ABCD001   +000080988116001+123
11+ABCD001   +000080988116001+123
12+ABCD001   +000080988116001+123
13+ABCD001   +000080988116001+123
10+ABCD001   +000080988116002+123
11+ABCD001   +000080988116002+123 
12+ABCD001   +000080988116002+123
13+ABCD001   +000080988116002+123 
10+ABCD001   +000080988116003+123
11+ABCD001   +000080988116003+123
12+ABCD001   +000080988116003+123
13+ABCD001   +000080988116003+123


I was looking in to samples given in the forum using WHEN=GROUP. But most of them looks like they increment for every record. Please let me know if this can be done through DFSORT.
Back to top
View user's profile Send private message
sergeyken

Senior Member


Joined: 29 Apr 2008
Posts: 2010
Location: USA

PostPosted: Thu Nov 09, 2017 11:03 pm
Reply with quote

Code:
 IFTHEN=(WHEN=GROUP,
         BEGIN=(1,2,CH,EQ,C'10'),
         END=(1,2,CH,EQ,C'13'),
         PUSH=(27:ID=3))

Common answer: RTFM

This was a very primitive question.
Back to top
View user's profile Send private message
srajendran2

New User


Joined: 13 May 2008
Posts: 56
Location: Chennai

PostPosted: Fri Nov 10, 2017 12:33 am
Reply with quote

sergeyken wrote:
Code:
 IFTHEN=(WHEN=GROUP,
         BEGIN=(1,2,CH,EQ,C'10'),
         END=(1,2,CH,EQ,C'13'),
         PUSH=(27:ID=3))

Common answer: RTFM

This was a very primitive question. Shame on those who call themselves "professionals"


Thanks for the help. i understand you've tried to help me. you may be an expert. Not everyone understands every topic explained in the manual because of the language. But it doesn't give the rights to "RTFM" or shame someone who is asking for help. The language was offensive for me. i request you to be considerate while replying.
Back to top
View user's profile Send private message
sergeyken

Senior Member


Joined: 29 Apr 2008
Posts: 2010
Location: USA

PostPosted: Fri Nov 10, 2017 12:52 am
Reply with quote

This forum is supposed to be used by some kind of experts, to clarify more or less sophisticated issues.

Unfortunately, 90% of new questions are at the same level of expertize as this example: "I'm given the task to multiply 2*2. I am new to REXX/Java/COBOL/JCL/SORT/... Can you, please, help me; it's very urgent"

There is a separate forum for beginners; everyone is welcome there, to clarify how to calculate 2*2
Back to top
View user's profile Send private message
srajendran2

New User


Joined: 13 May 2008
Posts: 56
Location: Chennai

PostPosted: Fri Nov 10, 2017 1:21 am
Reply with quote

sergeyken wrote:
This forum is supposed to be used by some kind of experts, to clarify more or less sophisticated issues.

Unfortunately, 90% of new questions are at the same level of expertize as this example: "I'm given the task to multiply 2*2. I am new to REXX/Java/COBOL/JCL/SORT/... Can you, please, help me; it's very urgent"

There is a separate forum for beginners; everyone is welcome there, to clarify how to calculate 2*2


When you say 90% of the questions are at the same level, i understand that there is no direction or recommendation of what can be posted in this forum. Or i think this is an input to group admin or site admin to have a message in the page where the user creates and submits the post to say only expert or high level questions can be posted here.
Back to top
View user's profile Send private message
Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1788
Location: Bloomington, IL

PostPosted: Fri Nov 10, 2017 5:24 am
Reply with quote

You will note that the top-left corner of this is a graphic calling this the "EXPERT FORUM".
Back to top
View user's profile Send private message
srajendran2

New User


Joined: 13 May 2008
Posts: 56
Location: Chennai

PostPosted: Fri Nov 10, 2017 11:36 pm
Reply with quote

Akatsukami wrote:
You will note that the top-left corner of this is a graphic calling this the "EXPERT FORUM".


Thanks for the update.

i have created multiple post and never noticed this. If you would like to avoid having simple issues to be posted, i would highly recommend to highlight in RED on the page where the post is created. just my thoughts. you can ignore, if it is not useful
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Mon Nov 13, 2017 8:15 pm
Reply with quote

Quote:
When you say 90% of the questions are at the same level, i understand that there is no direction or recommendation of what can be posted in this forum. Or i think this is an input to group admin or site admin to have a message in the page where the user creates and submits the post to say only expert or high level questions can be posted here.

If you ever have a doubt, post here regardless but after the proper research as usually similar questions certainly were answered in past.
Beginners Forum
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts Compare only first records of the fil... SYNCSORT 7
No new posts Pulling a fixed number of records fro... DB2 2
No new posts Substring number between 2 characters... DFSORT/ICETOOL 2
No new posts Generate random number from range of ... COBOL Programming 3
No new posts Increase the number of columns in the... IBM Tools 3
Search our Forums:

Back to Top