Hello,
I am using the code bellow to copy a template (zero observation data set) from Work to a server. This operation works well but when I click on my template located on the server, I have this error message:
The opening of the data has failed.
The following error occurred.
BOF or EOF is equal to true.
The current record has been deleted.
The requested operation requires a current record.
Data test;
stop;
set sashelp.class;
run;
Libname Template '\\...\Documents\My SAS Files\Template';
proc sql;
create table Template.Test_Templ like work.Test;
quit;
Any idea how to correct this problem?
regards,
Hello,
I have reported this issue to SAS.
Thanks for your help.
Regards,
Sorry, bit confused, your creating an empty dataset in SAS, then your create a copy of this somewhere else? I am not sure why. You could take a describe of dataset, then run that code on the destination, however if the destination is a database, then surely a better idea to use the table building tools on the database?
The error you get seems to tell you then answer:
"The requested operation requires a current record."
Therefore have one row, and then delete that row:
proc sql; create table template.test_templ like sashelp.class; delete * from template.test_templ; quit;
You can execute as many queries as you like.
hello,
I have try your code and I still have the same error.
Regards,
Hello,
I have reported this issue to SAS.
Thanks for your help.
Regards,
@alepage wrote:
Hello,
I am using the code bellow to copy a template (zero observation data set) from Work to a server. This operation works well but when I click on my template located on the server, I have this error message:
The opening of the data has failed.
The following error occurred.
BOF or EOF is equal to true.
The current record has been deleted.
The requested operation requires a current record.
Data test;
stop;
set sashelp.class;
run;
Libname Template '\\...\Documents\My SAS Files\Template';
proc sql;
create table Template.Test_Templ like work.Test;
quit;
Any idea how to correct this problem?
regards,
It sounds like there is a missing piece somewhere. Nnte of the code shown looks like it creates a data set "on a server".
Do you click on the data set inside a SAS session running on the server? From another program like a data base file list? A simple file manager?
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.
Find more tutorials on the SAS Users YouTube channel.