FAQ
Does anybody know any working example of using embedded MySQL library
for Win32 (libmysqld.dll)? That example from MySQL manual does not
work for me. I am looking for Python API to libmysqld.dll...

--
JZ

Search Discussions

  • Joe Francia at Nov 26, 2003 at 5:31 pm

    JZ wrote:
    Does anybody know any working example of using embedded MySQL library
    for Win32 (libmysqld.dll)?That example from MySQL manual does not
    work for me. I am looking for Python API to libmysqld.dll...
    You may want to consider this, which doesn't require you to ship any
    external DLLs:
    http://sourceforge.net/projects/mysql-python

    Joe
  • JZ at Nov 28, 2003 at 10:50 pm

    On Wed, 26 Nov 2003 17:31:35 GMT, Joe Francia wrote:

    Does anybody know any working example of using embedded MySQL library
    for Win32 (libmysqld.dll)?That example from MySQL manual does not
    work for me. I am looking for Python API to libmysqld.dll...
    You may want to consider this, which doesn't require you to ship any
    external DLLs:
    http://sourceforge.net/projects/mysql-python
    No, you did not understand me. I know this library and I have been
    using it for a long time. But the problem is I want to move my web
    (pythonic) application to CD and I wanted it to work with MySQL as a
    DLL library. I do not want to install full mysql serwer.
    I know how to use MySQLdb connection for a server, but I do not know
    how to connect to that dll. If MySQLdb can do this I do not know how
    use it. (MySQLdb.Connect() method has parameters of host, login but
    libmysql.dll do not need such parameters.)

    --
    JZ
  • JZ at Nov 29, 2003 at 1:51 am

    On Sat, 29 Nov 2003 01:00:34 GMT, Dennis Lee Bieber wrote:
    Does anybody know any working example of using embedded MySQL library
    for Win32 (libmysqld.dll)? That example from MySQL manual does not
    work for me. I am looking for Python API to libmysqld.dll...
    If I understand my book (hmmm, looks like New Riders has been
    swallowed by SAMS and renamed to "Developer's Library"), that DLL would
    have to be specified to the linker in place of the regular client
    protocol library. If so, to get Python to use it will likely require
    rebuilding the MySQLdb modules changing the linkage option.
    Do you know how to rebuild this module using Visual Studio 7 instead
    of v6? Is it possible?

    --
    JZ
  • Joe Francia at Nov 29, 2003 at 8:40 am

    JZ wrote:
    On Sat, 29 Nov 2003 01:00:34 GMT, Dennis Lee Bieber
    wrote:

    Does anybody know any working example of using embedded MySQL library
    for Win32 (libmysqld.dll)? That example from MySQL manual does not
    work for me. I am looking for Python API to libmysqld.dll...
    If I understand my book (hmmm, looks like New Riders has been
    swallowed by SAMS and renamed to "Developer's Library"), that DLL would
    have to be specified to the linker in place of the regular client
    protocol library. If so, to get Python to use it will likely require
    rebuilding the MySQLdb modules changing the linkage option.

    Do you know how to rebuild this module using Visual Studio 7 instead
    of v6? Is it possible?

    --
    JZ
    Unless you're totally married to MySQL, you may want to consider using
    one of the embeddable databases for Python, such as Sleepycat's
    Berkeley, Metakit, PySQLite, Kinterbase, etc. I've used Berkeley,
    Metakit and PySQLite, and they're all very good, each serving somewhat
    different needs. Shouldn't be too much effort to pull the data out of
    MySQL and into something else.

    Peace,
    Joe
  • JZ at Nov 29, 2003 at 9:07 am
    On Sat, 29 Nov 2003 08:40:56 GMT, Joe Francia wrote:

    Unless you're totally married to MySQL, you may want to consider using
    one of the embeddable databases for Python, such as Sleepycat's
    Berkeley, Metakit, PySQLite, Kinterbase, etc. I've used Berkeley,
    Metakit and PySQLite, and they're all very good, each serving somewhat
    different needs. Shouldn't be too much effort to pull the data out of
    MySQL and into something else.
    I do not want to use other database because my application *have to*
    work in full mysql server *and* (with _very_ little effort) with embed
    sql *without changing any sql queries*. It is multiplatform
    application (MySQL/Linux & MSSQL2k/Win32) I thought about SQlite, but
    it is no compatible with some queries. and I do not want to parse them
    with regular expressions.

    I checked mysql.h and I found the following piece of code:

    /*
    Set up and bring down the server; to ensure that applications will
    work when linked against either the standard client library or the
    embedded server library, these functions should be called.
    */
    int STDCALL mysql_server_init(int argc, char **argv, char **groups);
    void STDCALL mysql_server_end(void);

    Those functions seems to be *no implemented* in MySQLdb (I could not
    find them in _mysql.c file) :(

    If I understood the comment above, MySQLdb could be compiled with
    standard client library or with embed server library - not with both
    of them, right? :(

    --
    JZ
  • JZ at Nov 29, 2003 at 3:15 am

    On Sat, 29 Nov 2003 01:00:34 GMT, Dennis Lee Bieber wrote:
    Does anybody know any working example of using embedded MySQL library
    for Win32 (libmysqld.dll)? That example from MySQL manual does not
    work for me. I am looking for Python API to libmysqld.dll...
    If I understand my book (hmmm, looks like New Riders has been
    swallowed by SAMS and renamed to "Developer's Library"), that DLL would
    have to be specified to the linker in place of the regular client
    protocol library. If so, to get Python to use it will likely require
    rebuilding the MySQLdb modules changing the linkage option.
    I recompiled MySQLdb but I still do not know how to connect to embed
    server... :( MySQL.Connect(host=...)???? There is no example nor
    explanation. Not at all.

    --
    JZ

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppython-list @
categoriespython
postedNov 26, '03 at 11:30a
activeNov 29, '03 at 9:07a
posts7
users2
websitepython.org

2 users in discussion

JZ: 5 posts Joe Francia: 2 posts

People

Translate

site design / logo © 2022 Grokbase