What is the difference between io and extend when writing data to file?
Answers
Answered by
3
Hello,
In any file handling we have 4 modes
Input
Output
Extend
Delete
1. Input mode--> When ever we need to read the records, we use this. while suing this others can acess the data in view mode only ( Again it depends on the JCL DISP parameter)
2. Output mode--> When ever you want to write a freash into the dataset you use this mode. Note: When using this if some data exist it will be deleted.
Extend Mode--> when ever you need the data to be appened, continue for the last record you use it. when using this mode you can both read and write the data.
4. Delect mode--> this is for the record to be deleted.
In any file handling we have 4 modes
Input
Output
Extend
Delete
1. Input mode--> When ever we need to read the records, we use this. while suing this others can acess the data in view mode only ( Again it depends on the JCL DISP parameter)
2. Output mode--> When ever you want to write a freash into the dataset you use this mode. Note: When using this if some data exist it will be deleted.
Extend Mode--> when ever you need the data to be appened, continue for the last record you use it. when using this mode you can both read and write the data.
4. Delect mode--> this is for the record to be deleted.
Answered by
1
Answer:
A file should be opened in EXTEND mode, when you want to append the data in the file after the last record. I-O mode, you can Read/Update/both records.
Similar questions
Math,
8 months ago
Math,
8 months ago
History,
1 year ago
Math,
1 year ago
Business Studies,
1 year ago