BookmarkSubscribeRSS Feed
pathfinder1_1
Calcite | Level 5

Hi, I am reading an MPS file using this code. I got this code from this link. https://documentation.sas.com/?docsetId=casactmopt&docsetTarget=casactmopt_optimization_examples06.h...

 

proc cas;
example_fix_string = readpath ("&filepath."); 
loadactionset "optimization";
action optimization.loadMps /
mpsFileString = example_fix_string
casOut = {name = "example_fix" replace = true}
format = "FIXED";
run;
action table.fetch / table = "example_fix" to = 24;
run;
quit;

 

However, I get this error as shown in below error log. I wonder how to fix?

 

30 proc cas;
31 example_fix_string = readpath ("&filepath."); 
32 loadactionset "optimization";
33 action optimization.loadMps /
34 mpsFileString = example_fix_string
35 casOut = {name = "example_fix" replace = true}
36 format = "FIXED";
37 run;
ERROR: The server connection has not been specified
ERROR: Execution halted
38 action table.fetch / table = "example_fix" to = 24;
39 run;
ERROR: There is no server connection to execute the action 'table.fetch'.
ERROR: Execution halted
40 quit;

1 REPLY 1
RobPratt
SAS Super FREQ

I suspect that you have SAS/OR (SAS 9) and not SAS Optimization (SAS Viya).  If that is true, please try this example instead:

https://go.documentation.sas.com/?docsetId=ormpug&docsetTarget=ormpug_mpsds_sect024.htm&docsetVersio...

SAS Innovate 2025: Call for Content

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!

Submit your idea!

Multiple Linear Regression in SAS

Learn how to run multiple linear regression models with and without interactions, presented by SAS user Alex Chaplin.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 709 views
  • 0 likes
  • 2 in conversation