Page 1 of 1

Distributing dbExpress Application Error

Posted: Fri 06 Oct 2006 00:03
by marty6
I just got dbExpress for delphi 2006. I built a simple project, and I ran the exe on another box. On start-up it said: can't find dbexpmda.dll I was under the impression that, by using the direct connection (without libmysql.dll) I wouldn't need to include any other files with my program.

Posted: Fri 06 Oct 2006 13:52
by Antaeus
dbexpmda.dll is the driver itself that is used by dbExpress. It can access MySQL server directly without client library (libmysql.dll). You can embed the driver into your exe file so that no dlls will be necessary only if you have source code of it. Source code of the driver is available for registered users of DbxMda Professional version.

embedding dbexpmda.dll in exe

Posted: Fri 27 Apr 2007 18:15
by gjking
>You can embed the driver into your exe file

I am sure I have done this previously but can not remember on new machine and set up. Could someone please outline the specific steps to ensure this happens and can be deployed without additional .dll ?

many thanks in advance

graham

Posted: Sat 28 Apr 2007 15:09
by Antaeus
If you are user of DbxMda Professional Version, you can use something like this:

Code: Select all

uses
  ...dbxmda, ...;
...
initialization
  RegisterDbXpressLib(@getSQLDriverMySQLDirect);
end;
But you should keep in mind that you can't statically link more than one driver.
This is restriction of dbExpress technology.

ongoing problems compiling for deploying Direct connection

Posted: Fri 11 May 2007 08:08
by gjking
re: uses
...dbxmda, ...;
...
initialization
RegisterDbXpressLib(@getSQLDriverMySQLDirect);
end;

thanks, but with version 3.0 I had problem compiling,

and now have another with the new 3.20 version when put in uses ...dbxmda...

[Error] CRAccess.pas(88): Undeclared identifier: 'TConnLostCause' [Fatal Error] CRAccess.pas(490): File not found: 'CRConnectionPool.dcu'

I now have CRAccess unit, which was missing previously, but do not have CRConnectionPool.dcu. (although there is CRConnection.dcu)

this is with delphi 7 implementation

Posted: Fri 11 May 2007 15:09
by Antaeus
DbxMda and MyDAC (our Delphi Data Access Components for MySQL) use same core, but some core functionality cannot be used in DbxMda. The LITE directive splits this functionality, so both the driver itself and the application in which this driver is built, must be compiled with the LITE define.

Lite directive

Posted: Fri 11 May 2007 15:33
by gjking
OK - could you please explain the exact form and position of placing the LITE directive(s) ?

thanks

Posted: Fri 11 May 2007 15:54
by Antaeus
Call the "Project | Options" dialog from the IDE menu, and add the LITE define to the "Conditional defines" edit on the "Directories/Conditionals" tab.