Explain the difference between an internal and an external
sort, the pros and cons, internal sort syntax etc.

Answers were Sorted based on User's Feedback



Explain the difference between an internal and an external sort, the pros and cons, internal sort ..

Answer / vampire

Internal sort is manual sort use in cobol.
external sort is in jcl using inbuild program name called sort

ex

//step1 exec pgm=sort

synatx for internal sort

sort/merge sortfile on ascending/descending
key1/key2/key3,using file1/file2/input procedure is
section-1 giving file3/file4/output procedure is section-2


nobody can write syntax more than this.it is combination.

Is This Answer Correct ?    5 Yes 0 No

Explain the difference between an internal and an external sort, the pros and cons, internal sort ..

Answer / ajmal

I would like to add something to that.

External Sort's syntax

//SYSIN DD *
SORT FIELDS = (length of key, starting position of key,
CH, A/D)
/*
A - Ascending
D - Descending

Correct me if i'm wrong

Is This Answer Correct ?    3 Yes 4 No

Explain the difference between an internal and an external sort, the pros and cons, internal sort ..

Answer / mailid

Sort fields syntax is

//SYSIN DD*
SORT FIELDS=(START POSITION,LENGTH,A/D,DATATYPE)
/*

Is This Answer Correct ?    0 Yes 1 No

Post New Answer

More COBOL Interview Questions

I have the file which is having the extension no as records. sample file will look like below. 2310 3410 3256 4350 3781 5408 I need to replace the record which is starting with 3 to 5 (i.e) 3410 to 5410. How can we do it through cobol and cobol-db2 program? I need the possible logic?

5 Answers   RBS,


What is diff between vsam and db2?what is advantage of db2 over vsam?which is best suited one?

1 Answers   Fidelity,


in real time what is the suitable exp where in-stream procedure is better then catalog procedure.

1 Answers  


I have files that contains both duplicates files(occur more than twice) and non-duplicate files.The file is already sorted by a key.I want to determine those records that are duplicate and will be move to a duplicate file and non- duplicate files to be move to a valid file.thank you.help please

2 Answers  


I have a Main Program which is calling Sub-Program which is a DB2 pgm. What will happen if I am not closing the cursor used in the Sub-program? Please advise..

3 Answers   iGate,






What are some examples of command terminators?

1 Answers  


What are ISOLATION LEVELS? Where do we need to specify them in compiling JCL (Exactly which statement and what is syntax for it)?

2 Answers   T systems,


what is the use of keep and pass in disp

1 Answers  


I have a files containing both duplicate and non-duplicate records.The file is already sorted by a key.I want to determine those records that are duplicate and records that are non-duplicate.If duplicate the record is move to a duplicate file and if non-duplicate that will be move to valid file.thank you

1 Answers  


What is the difference between SEARCH and SEARCH ALL? What is more efficient?

9 Answers   IBM, iFlex, Wipro,


When is a scope terminator mandatory?

3 Answers  


without performing any operations on a file how can i know whether it contains data or not

2 Answers  


Categories