[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Help-glpk] Beware of using Access and Excel tables with ODBC (SQL
From: |
Noli Sicad |
Subject: |
Re: [Help-glpk] Beware of using Access and Excel tables with ODBC (SQL statement) in MathProg |
Date: |
Fri, 12 Feb 2010 07:48:33 +0700 |
Hi Andrew,
Yes, you are right. The coefficient in the distance between San Diego
- New York and San Diego Chichago were interchanged in Access and
Excel. I hand coded the Access data early morning (1AM) and export to
Excel the data the next day. While in sqlite I modified the SQL
statement from mysql for sqlite and run the sql statements.
I corrected the Access and Excel data. However, the Excel model still
persistent to have the wrong solution. I rebooted my computer. I do
again the ODBC setup for excel, to refresh the link. Still the excel
model got the wrong solution.
This is still solution to Excel
LOC1 LOC2 QUANTITY
San Diego New York 325
San Diego Topeka 275
Seattle Chicago 300
No entry for Seatle to New York.
Noli
On 2/12/10, Andrew Makhorin <address@hidden> wrote:
>> However, when converted
>> the 3 models into CPLEX format, the 3 models are exactly the same,
>> just ordering of the variables and constraints
>> (see converted models below).
>
> Not the same.
>
>> \* Problem: transp_odbc_sqlite3 *\
>
>> Minimize
>> cost: + 0.225 x(Seattle,'New_York') + 0.153 x(Seattle,Chicago)
>> + 0.162 x(Seattle,Topeka) + 0.225 x('San_Diego','New_York')
>> + 0.162 x('San_Diego',Chicago) + 0.126 x('San_Diego',Topeka)
>
>> \* Problem: transp_odbc_xls *\
>> Minimize
>> cost: + 0.225 x('San_Diego',Chicago) + 0.162 x('San_Diego','New_York')
>> + 0.126 x('San_Diego',Topeka) + 0.153 x(Seattle,Chicago)
>> + 0.225 x(Seattle,'New_York') + 0.162 x(Seattle,Topeka)
>
> transp_odbc_sqlite3:
> 0.225 x('San_Diego','New_York')
>
> transp_odbc_xls:
> 0.162 x('San_Diego','New_York')
>
>
- [Help-glpk] Beware of using Access and Excel tables with ODBC (SQL statement) in MathProg, Noli Sicad, 2010/02/11
- [Help-glpk] Beware of using Access and Excel tables with ODBC (SQL statement) in MathProg, Noli Sicad, 2010/02/11
- Re: [Help-glpk] Beware of using Access and Excel tables with ODBC (SQL statement) in MathProg, Andrew Makhorin, 2010/02/11
- Re: [Help-glpk] Beware of using Access and Excel tables with ODBC (SQL statement) in MathProg,
Noli Sicad <=
- Re: [Help-glpk] Beware of using Access and Excel tables with ODBC (SQL statement) in MathProg, Noli Sicad, 2010/02/11
- Re: [Help-glpk] Beware of using Access and Excel tables with ODBC (SQL statement) in MathProg, Noli Sicad, 2010/02/12
- Re: [Help-glpk] Beware of using Access and Excel tables with ODBC (SQL statement) in MathProg, Andrew Makhorin, 2010/02/12
- Re: [Help-glpk] Beware of using Access and Excel tables with ODBC (SQL statement) in MathProg, Noli Sicad, 2010/02/12
- Re: [Help-glpk] Beware of using Access and Excel tables with ODBC (SQL statement) in MathProg, Andrew Makhorin, 2010/02/12
Re: [Help-glpk] Beware of using Access and Excel tables with ODBC (SQL statement) in MathProg, Andrew Makhorin, 2010/02/11