| Back to Questions Page |
| Question |
I have a source program compiled with Cobol-2. The output
file has a record length of 100 defined in the program but
a record of 60 bytes getting written into it. i.e. The rest
of 40 bytes I am not Writing anything. But it by default
puts some values into the last 40 bytes. However it does
not impact anything. But when Compiled the module with
Enterprise Cobol the last 40 bytes were spaces as fillers.
Can anyone explain? |
Rank |
Answer Posted By |
|
Interview Question Submitted By :: Bishnu |
|
I also faced this Question!! |
© ALL Interview .com |
| Answer |
I think you ppl are hitting on wrong direction for
answering this question. The question doesn't seem to be
asking how to resolve a junk character, instead it's asking
about the different behaviour of the same program in two
different versions of Cobol - COBOLII and Enterprise COBOL.
One is placing junk characters in the last 40 bytes and the
other one intialized it to spaces. Any possible answer from
anyone now...?  |
0 | Vish |
| |
| |
| Answer |
it may be filled with null values. Junk charecters.
Due to before writing data it has to initialize.
That is the reason it is showing junk charecters.  |
0 | Ramanujam |
| |
| |
| Answer |
IN THE CASE OF FB , IT WILL FILL SPACE I.E, FILLER, BUT IN
VARAIBLE MODE YOU CAN'T SEE SPACE OR FILLER.  |
0 | Prashanth |
| |
| |
|
|
| |
| Answer |
hi
Before writing into the output file, just explicitly give
move spaces to rest of fields..
eg: ww-filler pic x(40) value spaces.
move ww-filler to ww-out-rec(61:40)
write ww-out-rec.
i hope the above code will resovle your problem.
Happy coding,
Ram.G  |
0 | Ram.g |
| |
| |
| Question |
What is the difference between SEARCH and SEARCH ALL? |
Rank |
Answer Posted By |
|
Interview Question Submitted By :: Guest |
|
I also faced this Question!! |
© ALL Interview .com |
| Answer |
search is a sequential/linear search and search all is
binary search  |
0 | Anil Prajapati |
| |
| |
| Answer |
in addition to the above answer the data to be searched
should be sorted in case of binary search  |
0 | Dev |
| |
| |
| Answer |
SEARCH
1)Linear/sequential search
2)No sorting order because its seq. order
3)access is slow
4)Any relational operator is used
SEARCH ALL
1)Binary search
2)Sorting either asc/dsc order
3)Access is faster
4)Only equal operator can be used.  |
0 | Sharath |
| |
| |
| Answer |
search is linear search. search the data based on condition.
search can work with multiple when conditions.
data is no need sorted order.
when ever we searching the data index clause must be used.
this will take more time compare with search all.
Search all:Binary search.
data must be a sequence either ascending or descending order .
only one when condition can be used.
this will take less time  |
0 | Karan |
| |
| |
|
| |
|
Back to Questions Page |