Hi
Is it possible to change the default file path for the my.ini file.
By default, this file is stored in the windows directory. Is it possible to store my.ini file in an other folder (none admin profile user are not allowed to write in the windows directory)
Context :
Delphi 7
MyDac : 7.0.2
embedded mode
Component : TMyConnection
Thanks
Joel
TMyConnection and property Params
-
DemetrionQ
- Devart Team
- Posts: 271
- Joined: Wed 23 Jan 2013 11:21
Re: TMyConnection and property Params
Hello.
MyDAC uses the libmysqld.dll library to connect to the MySQL embedded server. The library searches the my.ini file in the "C:\" and "C:\WINDOWS" directories (there are also other search paths depending on the libmysql.dll version). To solve the problem, you can use TMyEmbConnection instead of TMyConnection. TMyEmbConnection allows you to work without the my.ini file, providing access to the MySQL embedded server settings by the TMyEmbConnection.Params, TMyEmbConnection.BaseDir and TMyEmbConnection.DataDir properties. You can find detailed information about TMyEmbConnection and its properties in the MyDAC documentation.
MyDAC uses the libmysqld.dll library to connect to the MySQL embedded server. The library searches the my.ini file in the "C:\" and "C:\WINDOWS" directories (there are also other search paths depending on the libmysql.dll version). To solve the problem, you can use TMyEmbConnection instead of TMyConnection. TMyEmbConnection allows you to work without the my.ini file, providing access to the MySQL embedded server settings by the TMyEmbConnection.Params, TMyEmbConnection.BaseDir and TMyEmbConnection.DataDir properties. You can find detailed information about TMyEmbConnection and its properties in the MyDAC documentation.
-
joelthomas
- Posts: 2
- Joined: Wed 12 Jun 2013 14:21
Re: TMyConnection and property Params
Hi,
Thanks for your answer.
Our internal framework is based on the TMyConnection component and it takes a lot of time to change it.
is there any other solution with a TMyConnection component ? I just need to transfer to the mysql dll, the path to store the my.ini file.
Thanks
Joel
Thanks for your answer.
Our internal framework is based on the TMyConnection component and it takes a lot of time to change it.
is there any other solution with a TMyConnection component ? I just need to transfer to the mysql dll, the path to store the my.ini file.
Thanks
Joel
-
DemetrionQ
- Devart Team
- Posts: 271
- Joined: Wed 23 Jan 2013 11:21
Re: TMyConnection and property Params
Hello.
The TMyConnection component doesn't provide a possibility to modify Embedded connection parameters. For this, you should use TMyEmbConnection. To change this behaviour, you can buy MyDAC with source code and add the possibility to set parameters via TMyConnection by yourself.
The TMyConnection component doesn't provide a possibility to modify Embedded connection parameters. For this, you should use TMyEmbConnection. To change this behaviour, you can buy MyDAC with source code and add the possibility to set parameters via TMyConnection by yourself.