Please read the below code. It can read MPS file. How can I get each variable from m? Please share the code.
using JuMP
using GLPK
using MathOptInterface
const MOI = MathOptInterface
mathoptformat_model = MOI.FileFormats.Model(format = MOI.FileFormats.FORMAT_MPS)
FILE_NAME=“E:\file1.mps”
MOI.read_from_file(mathoptformat_model, FILE_NAME)
m = Model(GLPK.Optimizer)
MOI.copy_to(m, mathoptformat_model)