Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

If a field is declared as a comp-3 field and if we want to
sort a dataset based on this field, then how will the sort
card be???

e.g- if we want to sort by a field which is defined as a
PIC X(5) then we will mention - sort fields=(1,5,ch,a).
Likewise if a field is defined as PIC S9(10)COMP-3 then in
this case how will the sort field be defined (because in
this case a sign is also involved)???

Answer Posted / muttiah

Let's discuss what are all formats we have in sort
X/A - CH
Comp - BI
Comp-3- PD
9 - ZD/CH
So, Here we need to calculate how many bytes does the field
S9(10)comp-3 occupies.
10/2 + 1 = 5 + 1 = 6 bytes
Say field start's @ position 10then the sort command would
be like this..
Sort fields=(10,6,PD,A/D)
Hope this clarifies

Is This Answer Correct ?    9 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

which parameter is used to check the syntax of a jcl without executing it?

1363


What are s0c1, s0c4, s0c5, s0c7 and socb?

1177


How can the attributes of one sms dataset be copied to another dataset?

1424


Explain the function of dd disp parameter?

1124


What is the purpose of disp parameter?

1128


I have a COBOL program that ACCEPTs some input data. How do you code the JCL statement for this?

1199


what are the types of abends that occur on job failure? And explain the possible causes of these

1624


what is the purpose of coding class parameter in job statement?

1263


How jcl work to handle various input output file operations?

1169


what sort card you will use to copy the data from one dataset to another dataset?

1230


what is JCL?

1165


Mention the types of job control statements?

1174


Explain about ISPF/TSO Commands

1950


i want to store 20 digits . how will u do it in cobol ?

1421


What are some jcl statements that are not allowed in procedures?

1236