Application Development and Automation 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: 
Read only

Open Dataset

Former Member
0 Likes
1,077

We are trying to run an Open Dataset command against a file that is sitting on the server that the SAP system is sitting. When the Open Dataset command is ran, where is the server configured so that it knows to access a file on that server? We are getting an error stating that it can't find the file, but we are not sure which server it's trying to access.

Any help would be greatly appreciated.

Thanks,

Dale Dingmann

1 ACCEPTED SOLUTION
Read only

amit_khare
Active Contributor
0 Likes
949

As far as I know, OPEN DATASET can only check the machines connected to same network.

Remotely connected machins need FTP to transfer files.

To check the path of the file just try AL11 tcode. Its not necessary to see that path there, depends on the Basis settings.

Best way is to try to open the file from NETWORK NEIGHBORHOOD of your desktop (If its windows) if you can then use the same path in your OPEN DATASET statement.

If you cannot access from that path then use FTP.

5 REPLIES 5
Read only

amit_khare
Active Contributor
0 Likes
950

As far as I know, OPEN DATASET can only check the machines connected to same network.

Remotely connected machins need FTP to transfer files.

To check the path of the file just try AL11 tcode. Its not necessary to see that path there, depends on the Basis settings.

Best way is to try to open the file from NETWORK NEIGHBORHOOD of your desktop (If its windows) if you can then use the same path in your OPEN DATASET statement.

If you cannot access from that path then use FTP.

Read only

0 Likes
949

We know where the file is located. We are actually specifying the file path in the selection screen of the program. However, it's not able to read the file on the server. That's the part we are uncertain as to how it knows which server it's connecting to. The question is what are those basis settings.

Read only

0 Likes
949

First thing plz ensure your file is not corrupted.

Second,i suppose u have 2 to 3 applications servers supporting ur SAP system.Then wat happens when u run the program in background,the program automatically stores the file in any of the supported application servers with the given path.and while fetching the file from the server it searches from the other application server.

so while running the program in background , when u schedule the job first give the server name nanually by changing the job......when u find the server name run the program for extracting the file in that server only.

Means ensure that the downloading the file to app server and extraction has same application servers

regards

kanishak

Read only

Former Member
0 Likes
949

Hi dale,

For a SAP server we can hv multiple application servers supporting the database.In your case there is a possibility of the same. i.e. While downloding the data on appl server system RANDOMLY picks the application server out of the multiple once.And while fetching again system randomly accesses the appl server.So if by luck system selects the same appl server in which the file is stored then u can get the file otherwise not.

The sol is, first schedule the entire program in background if u dnt have any GUI FMs else use FM JOB_OPEN , JOB_SUBMIT, JOB_CLOSE.

Once the job is finished through SM37, double click on the jon name....select button "job details" on appl toolbar.chk the field "Executing server" .

There u ll get actual server name.

Noe while fetching the data from appl server again schedule the job with future time.

Select the jon in SM37 .Goto job -> change. Slect the field "Exce target"...here in F4 help u ll get all the servers present.Select the one where actually data has sat.

You ll get the data.

regards,

ajit.

Read only

JoffyJohn
Active Contributor
0 Likes
949

their is a function module

ARCHIVFILE_CLIENT_TO_SERVER

Path( is ur local PC path): eg:D:\BACKUP\TEXT.XLS

Target path( is the application server location: As seen in Tcode:AL11)

eg:E:\USR\SAP\E6D\DVEBMGS00\DATA\TEXT.XLS

When you execute this function module.

THe file from PC will be put to application server.

Then use open data set to open this file.

If this is working try with your real file.