AMPL Direct Spreadsheet Interface

10 views
Skip to first unread message

Azadeh Sadeghi

unread,
Jul 13, 2022, 2:45:39 AM7/13/22
to AMPL Modeling Language
Hello,

I face an error while reading a table in AMPL. Here is the error:
Error reading table  TravelTime  with table handler amplxl:
could not find a range or sheet named TravelTime
Attached please find my run file and spreadsheet.

Thanks,
TravelTime_AMPL_V2.xlsx
2_5_Sc1_Excel.run

AMPL Google Group

unread,
Jul 13, 2022, 5:54:07 PM7/13/22
to AMPL Modeling Language
You need to establish a correspondence between the table in AMPL and the table in the spreadsheet.
In your particular case it will be enough to rename sheet2 in the spreadsheet to TravelTime. AMPL will automatically search for the columns SCENARIO, FROM, TO and T and load the data for parameter T.
I don't have all the files you are using but note you also need to provide values for the sets SCENARIO, FROM and TO (perhaps in their own tables?).

Hope this helps!
Best regards,

Nicolau


--
Nicolau Santos
am...@googlegroups.com
{#HS:1947688189-110961#}
Reply all
Reply to author
Forward
0 new messages