Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Getting first record of a particular partition in IMS DB

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IMS DB/DC
View previous topic :: :: View next topic  
Author Message
Paresh0459

New User


Joined: 22 May 2007
Posts: 8
Location: Mumbai

PostPosted: Tue Dec 20, 2011 10:36 pm    Post subject: Getting first record of a particular partition in IMS DB
Reply with quote

Hi,
I have a HALDB Databse that has 84 partitions with key record as YYMMXXXXXXXXXXXXX. it also has a secondary index.

Partitions are based on YYMM varying from 0000 to 0612. X is a alphanumeric .
I wish to delete everything residing in a particular partition say 0301. In my program i issue a qualified SSA with GHN using PCB of primary index. SSA is defined on partial index with value varying from 0301x'0000000000000' to 0301x'FFFFFFFFFFFFF'. This is to have all records which falls under this range in 0301 partition.
After this GHN i issue a DLET call and later on I issue a unqualified GHN to get next record in database. this is followed by DLET call.
This process is repeated untill I find a record with different partition number.

Now the problem I'm facing is with the first qualified GHN call. It seems that call does not point to first record from 0301 partition, as once the job was complete, i could still see records from 0301 partition.

Could you please let me know how can I get first record from the partition?

Thanks in advance

Paresh
Back to top
View user's profile Send private message

Ed Goodman

Active Member


Joined: 08 Jun 2011
Posts: 556
Location: USA

PostPosted: Wed Dec 21, 2011 9:28 pm    Post subject:
Reply with quote

If the database in an HDAM and not a HIDAM, then the root keys will not be in sequence inside the database. They will be randomized.

Unless you use that partition selection parm in the DFSVSAMP input file, an IMS program will treat the database as if it was one single partition.

You might want to consider something like initializing the single partition and rebuilding the index (all indexes). That would probably be faster, but you'd need to get exclusive access to do it.
Back to top
View user's profile Send private message
manikawnth

New User


Joined: 07 Feb 2007
Posts: 61
Location: Mumbai

PostPosted: Thu Dec 29, 2011 2:54 pm    Post subject: @Paresh
Reply with quote

HI PJ,

As Ed told, HDAM database roots are stored randomly indexed by root anchor points which were generated by randomizing module.

The simple approach left for you is to hit all GHU calls
varying from 0301x'0000000000000' to 0301x'FFFFFFFFFFFFF' and delete them...
Back to top
View user's profile Send private message
manikawnth

New User


Joined: 07 Feb 2007
Posts: 61
Location: Mumbai

PostPosted: Thu Dec 29, 2011 4:28 pm    Post subject: @A;;
Reply with quote

Correct me if I'm wrong:
Can't it be run in a DLI mode bringing down the d/bs and just giving the selected partition in DD name?
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10350
Location: italy

PostPosted: Thu Dec 29, 2011 7:14 pm    Post subject: Reply to: Getting first record of a particular partition in
Reply with quote

just a philosophical/general remark...
if You delete all the database records within a certain key range x'0301zzz' ( x'00...00' <= zzz <= x'ff..ff' )
the partition where they reside should be irrelevant to the process
and finding some of them after the <delete> is just a symptom of some glitch in the process
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IMS DB/DC All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Extract Record using range of Data scorp_rahul23 DFSORT/ICETOOL 3 Wed Nov 15, 2017 11:54 pm
No new posts Squeeze record left so that zeroes ar... Vignesh Sid SYNCSORT 5 Fri Nov 10, 2017 1:40 pm
No new posts Formatting multiple records to a sing... Vignesh Sid SYNCSORT 3 Tue Nov 07, 2017 12:22 pm
No new posts Format Last Record differently from r... Learncoholic DFSORT/ICETOOL 5 Tue Oct 24, 2017 12:01 pm
No new posts Copy 4 byte of data from the last rec... arunsoods DFSORT/ICETOOL 9 Fri Oct 06, 2017 12:15 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us