Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Sorting an alphanumeric field which has date values in it..

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
roopesh_vp
Currently Banned

New User


Joined: 30 Jan 2009
Posts: 2
Location: Mysore

PostPosted: Fri Mar 20, 2009 2:50 pm    Post subject: Sorting an alphanumeric field which has date values in it..
Reply with quote

Hi All,

I want to sort a ps based on the value of the clumn 'last used'( some sample values for that column is given below)
LAST USED

02/20/09
12/07/07
01/31/08
12/28/06
*NEVER*
01/16/09
02/13/09
*NEVER*
*NEVER*
04/04/07
*NEVER*
08/24/06

It has both date fields and the string *NEVER* .. Can i sort this field in descending order of date and move all *NEVER* records to the botton of the file??? Is it possible to do this using a COBOL program or easytrieve...??

Thanks in advance
Back to top
View user's profile Send private message

dbzTHEdinosauer

Global Moderator


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

PostPosted: Fri Mar 20, 2009 2:59 pm    Post subject:
Reply with quote

since numbers are represented as hex F0 (0) thru F9 (9) and letters/special characters are represented as hex C1 (A) thru E?,
you are not going to be able to desc sort without changing the value of '*never*' to something like '9never*'.
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 -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Check Binary Values for symbols gandikk CA Products 3 Tue Mar 21, 2017 5:11 am
No new posts Date and time format in CICS Chandru3183 CICS 2 Sat Mar 18, 2017 12:46 pm
No new posts SORT VSAM file with each field one by... maxsubrat DFSORT/ICETOOL 6 Tue Mar 14, 2017 1:07 pm
No new posts IMS DB-How to update a record (a sing... Nic Clouston IMS DB/DC 9 Thu Mar 09, 2017 4:38 pm
No new posts To display values of multiple rows in... vinu78 DB2 2 Thu Mar 09, 2017 1:20 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us