Download MetaTrader 5

Output test results to SQL database

To add comments, please log in or register
Do you want to learn MQL5? 300 articles will help you!
Maka4Tune
26
Maka4Tune 2016.07.22 16:25 

I would like to run some strategy tests and output results to a SQL Database so that I can run some reports and see which ones are more profitable. Has anyone achieved this before?

Al 

Marco vd Heijden
Moderator
4704
Marco vd Heijden 2016.07.22 16:32  
Maka4Tune:

I would like to run some strategy tests and output results to a SQL Database so that I can run some reports and see which ones are more profitable. Has anyone achieved this before?

Al 

I don't think that will work.
Maka4Tune
26
Maka4Tune 2016.07.22 17:33  
Marco vd Heijden:
I don't think that will work.

Thanks for the relentless positivity. 

 Is it possible to send http requests, I could build something that receives values in a URL and writes it into a DB?

Marco vd Heijden
Moderator
4704
Marco vd Heijden 2016.07.22 17:40  
Maka4Tune:

Thanks for the relentless positivity. 

 Is it possible to send http requests, I could build something that receives values in a URL and writes it into a DB?

I meant the part about seeing which ones are more profitable.

More profitable in what sense ?

Frederic Metraux
511
Frederic Metraux 2016.07.22 17:48  

Hello,

I've used this library: https://www.mql5.com/en/articles/862

Uses SqLite database, wich works well if you run only one instance of the EA and write only one record at a time because it is mono user. The advantage is that it is easy to use.


And this one: https://www.mql5.com/en/forum/718

It works very well with multiple instances of the EA because it uses SQL Server database which is a robust db. More tricky, if you aren't experienced with databases, expect to put some efforts in learning, specially the connection. You also need to recompile the DLL if you use a 64 bit system.

SQL and MQL5: Working with SQLite Database
SQL and MQL5: Working with SQLite Database
  • 2014.04.18
  • o_O
  • www.mql5.com
This article is intended for developers who would be interested in using SQL in their projects. It explains the functionality and advantages of SQLite. The article does not require special knowledge of SQLite functions, yet minimum understanding of SQL would be beneficial.
Maka4Tune
26
Maka4Tune 2016.07.24 11:33  
twalk:

Hello,

I've used this library: https://www.mql5.com/en/articles/862

Uses SqLite database, wich works well if you run only one instance of the EA and write only one record at a time because it is mono user. The advantage is that it is easy to use.


And this one: https://www.mql5.com/en/forum/718

It works very well with multiple instances of the EA because it uses SQL Server database which is a robust db. More tricky, if you aren't experienced with databases, expect to put some efforts in learning, specially the connection. You also need to recompile the DLL if you use a 64 bit system.

That's awesome, thank you. Just what i was looking for :-) 

To add comments, please log in or register