2008 Nov 24 5:57 AM
Hi Friends,
I have a file 'abc' in application server, and i don't know the extension of it . while trying to open it using OPEN DATASET statement, it fails because of no extension.
I have tried using 'abc.*' in the open dataset statement but it doesnt work....so is there any function module or is there any other way to open and read it.........
Hi Friends,
I have a file 'abc' in application server, and i don't know the extension of it . while trying to open it using OPEN DATASET statement, it fails because of no extension.
I have tried using 'abc.*' in the open dataset statement but it doesnt work....so is there any function module or is there any other way to open and read it.........
2008 Nov 24 6:04 AM
Hi Shylaja,
could you able to open the file abc in application layer.
Regards
Rasheed
2008 Nov 24 6:09 AM
Hi,
Use the function module open_dataset and pass the parameter using abc.txt and check it out
Thanks,
Thiru.r
2008 Nov 24 6:18 AM
>
> I have a file 'abc' in application server, and i don't know the extension of it . while trying to open it using OPEN DATASET statement, it fails because of no extension.
Its totally wrong to say OPEN DATASET statement failed because of no extension of the file! Actually, the ABAP run-time does not care whether the file has an extension or not. In most cases, the app server (file system) datasets/files are stored without any extension.
Here's how to approach your issue:
1. Read the Keyword Documentation of OPEN DATASET
2. Check the Sy-Subrc after OPEN DATASET statement and if its unequal to 0;
a. Check the file name/path you are passing is correct
b. Check you are using OPEN DATASET for READ
c. Depending you are in a Unicode/Non-Unicode system, check the file is not already open
d. Make sure the file you are trying to open physically exists in the app server!
Once you are able to OPEN the file then use READ DATASET command to read it.
Hope this helps.
Cheers,
Sougata.
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |