Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Using odbc load, table with MySQL


From   "Thomas Jacobs" <thomasjacobs@gmail.com>
To   StataList <statalist@hsphsun2.harvard.edu>
Subject   st: Using odbc load, table with MySQL
Date   Wed, 16 Jul 2008 17:14:34 -0500

I am trying to use the odbc commands to connect to a non-local MySQL
database.  I have had success with odbc query, odbc describe and odbc
list but not odbc load

. odbc load, table("tradeday_libor") dsn("MarkitCDS")
Connection Parameters (IN): DSN=MarkitCDS;
Connection Parameters (OUT):
DATABASE=markitcds;DSN=MarkitCDS;OPTION=0;PWD=cmpqmysql;PORT=3306;SERVER=HP2;UID=CMPQ
[MySQL][ODBC 3.51 Driver][mysqld-5.0.45-community-nt]You have an error
in your SQL syntax; check the manual that corresponds to your MySQL
server version for the right syntax to use near '"tradeday_libor"' at
line 1
r(682);

if I execute the similar command I get a successful result:

. odbc load, exec("select * from tradeday_libor") dsn("MarkitCDS")
Connection Parameters (IN): DSN=markitcds;
Connection Parameters (OUT):
DATABASE=markitcds;DSN=markitcds;OPTION=0;PWD=cmpqmysql;PORT=3306;SERVER=HP2;UID=CMPQ

so my question is, what am I doing wrong in the load, table command?  Thanks.

Tom
--
Thomas Jacobs
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index