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-wordmark-2025-midnight.png

Register Today!

Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.


Register now!

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
  • 829 views
  • 0 likes
  • 2 in conversation