Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

weird problem in open dataset

Former Member
0 Kudos
869

Hi mate,

I have strange problem with open dataset. I try to download data to server and hit by shortdump telling me that file is not yet opened. I have checked SY-SUBRC (equals zero) after statement open dataset.

It just happened today, previously i never encounter these problem before.

Can someone point out me what the problem is? is it because of some delay in opening dataset or system performance issue? Production is running pretty slow in peak hours around 10-13PM.

Thanks for your input.

alia

6 REPLIES 6

Former Member
0 Kudos
151

Hi Alia,

Hope u have closed ur file(closed AL11 txn.) before executing you code.

This somtimes causes problems.

Pls chek this too.

Data: v_filepht LIKE FILENAME-FILEINTERN, "Physical file for p_fnam2


FORM f1104_download_to_lofile.

* Open the file in application server
  OPEN DATASET v_filepht FOR OUTPUT IN TEXT MODE.

  IF sy-subrc <> 0.
    MESSAGE s185 WITH v_filepht.           " File opening error
    LEAVE LIST-PROCESSING.
  ENDIF.

  LOOP AT i_logfile INTO w_logfile.
    TRANSFER w_logfile TO v_filepht.
    CLEAR w_logfile.
  ENDLOOP.

  IF sy-subrc = 0.
    WRITE:/ text-055, v_filepht, text-056. " File successfully created
  ELSE.
    WRITE:/ text-057, v_filepht.           " Error creating file
  ENDIF.

* Closing the file
  CLOSE DATASET v_filepht.

ENDFORM.                    " f1104_download_to_lofile

Regards,

Anjali

Former Member
0 Kudos
151

Hi Anjali,

I have put 'close dataset' after transfering the data.

many thanks

Alia

Former Member
0 Kudos
151

Hi alia,

1. did u see thru al11 whether the file

already exists or not ?

2. please note that file names

(along with the full path)

are CASE SENSITIVE (in unix, aix)

regards,

amit m.

ferry_lianto
Active Contributor
0 Kudos
151

Hi Alia,

Please check SAP OSS Note <b>733626</b>. It seems you don't have enough space in application server when the system tries to generate the input file. Perhaps you may need to archive production files.

<b>Symptom</b>

Report RCCLBI03 classifies all objects that are contained in an input file. Incorrect records from the input file are written into an error file.

The report generates a termination with error code DATASET_CANT_OPEN if an object must be really written into the error file.

<b>Other terms</b>

Classification, dump

<b>Reason and Prerequisites</b>

The check whether the error file can be opened is insufficient. In the standard case this is RCCLBI03.ERROR on the application server.

<b>Solution</b>

If the error file cannot be opened, the report now ends with error message LX105 ("Unable to open file &1"). Then the input file is no longer imported.

Hoep this will help.

Regards,

Ferry Lianto

abdul_hakim
Active Contributor
0 Kudos
151

Hi Alia,

Check whether the file exists using AL11.

Also note that file names are case sensitive..

Cheers,

Abdul Hakim

0 Kudos
151

Hi to all

Truely which these errors happen and sometimes is very difficult to to consider it, fortunately this forum has people like you.

My error was by small letters,

Thank you very much !!

regards

Dario