DDBI and MySQL
Chris R. Miller
lordSaurontheGreat at gmail.com
Fri Aug 29 00:47:30 PDT 2008
I've been working to attempt to get DDBI to work with MySQL.
Unfortunately I'm stuck with the Windows platform for lack of the
impetus and know-how to get the compiler working elsewhere.
I use a slightly modified version of DDBI to get SQLite to work. I
don't think that would disrupt the workings of MySQL.
Once I found the correct library file to use (buried in a large download
of MySQL - the server, which was annoying) I found that the whole
she-bang didn't work at all. It was all tied to a strange external
declaration in imp_win.d, which apparently decided that on Windows the
MySQL support is provided by extern(Windows) instead of extern(C).
Once I got that cleared up, I started a bunch of "cannot implicitly cast
foo* to foo*" errors, which mystified me. I think it's because one is
tossing an alias of something to something that's expecting the
un-aliased something, and so it's having some issues.
So attempting to fix the issues didn't work terribly well. I beat
through a few pointer issues to get hung up on a weird pointer issue
which emits this error:
dbi\mysql\MysqlDatabase.d(194): constructor
dbi.mysql.MysqlResult.MysqlResult.th
is (st_mysql_res*) does not match parameter types (st_mysql_res*)
dbi\mysql\MysqlDatabase.d(194): Error: cannot implicitly convert
expression (cas
t(st_mysql_res*)*results) of type st_mysql_res* to st_mysql_res*
I'm pretty puzzled. I've tried casting it explicitly, and it doesn't
work. I'd really appreciate it if someone knew what is going on. When
I explicitly cast it, it still give the same error.
This is DMD version 1.033.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 258 bytes
Desc: OpenPGP digital signature
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20080829/631ac79d/attachment.pgp>
More information about the Digitalmars-d
mailing list