How to import multiple parameters using GDXXRW

Hi,
Can anybody please help regarding this problem ?

I need to import multiple parameters from excel to GAMS in a single gdx file.
this is the statement i am using

$CALL GDXXRW.EXE NLP_Input_3x3.xls par=Ibn rng=ip!B2:C25 Rdim=1 par=Ta rng=ip!V2:W25 Rdim=1 par=ml_1 rng=ip!D2:E25 Rdim=1 par=TLout1 rng=ip!F2:G25 Rdim=1 par=ml_2 rng=ip!J2:K25 Rdim=1 par=TLout2 rng=ip!L2:M25 Rdim=1 par=ml_3 rng=ip!P2:Q25 Rdim=1 par=TLout3 rng=ip!R2:S25 Rdim=1 par=TLin1 rng=ip!H2:I25 Rdim=1 par=TLin2 rng=ip!N2:O25 Rdim=1 par=TLin3 rng=ip!T2:U25 Rdim=1

I get Error 495 in the output

if i divide the parameters in multiple gdxxrw statements then all parameters get imported (but i don’t get the single gdx file having all parameters).

Any help is appreciated.

Thanks and regards
Chinmay


To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at http://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.

Hi Chinmay



Add Trace = 3 at the end of your call, so you can see what is going wrong. It might also be a good idea to put all this information in a text file or directly into the excel sheet. It is described in the gdxutils.pdf.

That would make it much more easy to handle.

Cheers

Renger


Modelworks

Gewerbestrasse 15

3600 Thun – Switzerland

+41 79 818 53 73

Info@modelworks.ch

blog.modelworks.ch







From: gamsworld@googlegroups.com [mailto:gamsworld@googlegroups.com] On Behalf Of Chinmay Kinjavdekar
Sent: Freitag, 18. April 2014 17:06
To: gamsworld@googlegroups.com
Subject: How to import multiple parameters using GDXXRW





Hi,

Can anybody please help regarding this problem ?



I need to import multiple parameters from excel to GAMS in a single gdx file.

this is the statement i am using



$CALL GDXXRW.EXE NLP_Input_3x3.xls par=Ibn rng=ip!B2:C25 Rdim=1 par=Ta rng=ip!V2:W25 Rdim=1 par=ml_1 rng=ip!D2:E25 Rdim=1 par=TLout1 rng=ip!F2:G25 Rdim=1 par=ml_2 rng=ip!J2:K25 Rdim=1 par=TLout2 rng=ip!L2:M25 Rdim=1 par=ml_3 rng=ip!P2:Q25 Rdim=1 par=TLout3 rng=ip!R2:S25 Rdim=1 par=TLin1 rng=ip!H2:I25 Rdim=1 par=TLin2 rng=ip!N2:O25 Rdim=1 par=TLin3 rng=ip!T2:U25 Rdim=1



I get Error 495 in the output



if i divide the parameters in multiple gdxxrw statements then all parameters get imported (but i don’t get the single gdx file having all parameters).



Any help is appreciated.



Thanks and regards

Chinmay


To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at http://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.


To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at http://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.

Thanks a lot Renger !
I added Trace=3 at the end, and now i am getting Error 331: Parameters longer than 80 characters.

Regards

Chinmay


To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at http://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.

I found the way to use txt file. Thanks a lot !

Regards,
Chinmay


To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at http://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.