I'm working at Upwork only on one big project currently. So, have no much free time nowadays. What's the problem you have with libs? How can I help you?
Hello,
I figured it out in the end, but thanks for the library anyway.... Very helpful!!
I am trying to connect Metatrader to Mysql via your files.
After the download and the installation I changed the file "MyConnection" by setting the info of my DB.
Here goes the problem:
At first, everything worked just fine; the scripts were creating tables inside the DB. Then I made a little change in the code (just changed the table's name) and deleted the table from the database so that the script would create a new one from scratch without droping the previous one. And all I got was the creation of the columns but without any data.
So I decided to use the old scripts again. Then I got nothing; not even a table was created. Since then I have a DB that stays empty.
I am trying to connect Metatrader to Mysql via your files.
After the download and the installation I changed the file "MyConnection" by setting the info of my DB.
Here goes the problem:
At first, everything worked just fine; the scripts were creating tables inside the DB. Then I made a little change in the code (just changed the table's name) and deleted the table from the database so that the script would create a new one from scratch without droping the previous one. And all I got was the creation of the columns but without any data.
So I decided to use the old scripts again. Then I got nothing; not even a table was created. Since then I have a DB that stays empty.
creates a table with the given name. You must have the privilege for the table. Rules for permissible table names are given in Section 9.2, “Schema Object Names”. By default, the table is created in the default database, using the storage engine. An error occurs if the table exists, if there is no default database, or if the database does not...
To create table use SQL command CREATE TABLE http://dev.mysql.com/doc/refman/5.7/en/create-table.html
For inserting data use SQL command INSERT INTO https://dev.mysql.com/doc/refman/5.6/en/insert.html
To execute such commands use the function MySqlExecute.
Also you can provide your code and I would be able to figure out the problem.
Hello Eugeniy,
Thank you for the links.
At first I used your code to connect to my database (I was using mySql Server in case it is useful). And I could see the table. Then I changed the table's name at your MySQL-002 Script (as you can see below) and thought it seemed to work it wouldn't create my table. Now I'm using WampServer and I get:
At first I used your code to connect to my database (I was using mySql Server in case it is useful). And I could see the table. Then I changed the table's name at your MySQL-002 Script (as you can see below) and thought it seemed to work it wouldn't create my table. Now I'm using WampServer and I get:
Based on error I see from your log: 0 11:09:37.742 MySQL-002 EURUSD,H1: Table `table` cannot be created.
you are uses name "table" which is keyword of mysql database and cannot be used as table name, try to change to for example to "table1" just to check is it works.
or possible the database was not selected or was not set. you can execute command "USE database_name" right after connection, where the database_name is the name of your database.
for example if my database is "mysql":
DB = MySqlConnect(Host, User, Password, Database, Port, Socket, ClientFlag);
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Hello James,
I'm working at Upwork only on one big project currently. So, have no much free time nowadays. What's the problem you have with libs? How can I help you?
Why did everything stop working after upgrading to build 890 mt4?
The log says Access violation read to 0x00000000 in 'D:\MT4\MQL4\libraries\MQLMySQL.dll'.
also interested in ...
Looking forward to it!
MT4 build 890 x32 just checked. Everything works.
Log of running test scripts:
Guys, clarify:
1. On what operation it gives"Access violation read" ?
2. When running the MySQL-001 script, what version of MQLMySQL is shown on the Experts tab? should be: MQLMySQL v2.2 x32 Copyright © 2014, FxCodex Laboratory
3. What version of MySQL database?
4. Is MySQL used locally or on a remote host?
5. Under which operating system do you run the terminal?
Please check and report back, as I can't reproduce the error.
I will create a similar environment and test.
Hello,
Here goes the problem:
Any ideas of what could possibly have gone wrong?
Thanks in advance!
Hello,
Here goes the problem:
Any ideas of what could possibly have gone wrong?
Thanks in advance!
Hello Peg,
To create table use SQL command CREATE TABLE http://dev.mysql.com/doc/refman/5.7/en/create-table.html
For inserting data use SQL command INSERT INTO https://dev.mysql.com/doc/refman/5.6/en/insert.html
To execute such commands use the function MySqlExecute.
Also you can provide your code and I would be able to figure out the problem.
Hello Peg,
To create table use SQL command CREATE TABLE http://dev.mysql.com/doc/refman/5.7/en/create-table.html
For inserting data use SQL command INSERT INTO https://dev.mysql.com/doc/refman/5.6/en/insert.html
To execute such commands use the function MySqlExecute.
Also you can provide your code and I would be able to figure out the problem.
Hello Eugeniy,
Thank you for the links.
At first I used your code to connect to my database (I was using mySql Server in case it is useful). And I could see the table. Then I changed the table's name at your MySQL-002 Script (as you can see below) and thought it seemed to work it wouldn't create my table. Now I'm using WampServer and I get:
0 11:09:37.579 Script MySQL-002 EURUSD,H1: loaded successfully
0 11:09:37.730 MySQL-002 EURUSD,H1: initialized
0 11:09:37.730 MySQL-002 EURUSD,H1: MQLMySQL v2.0 Demo Copyright © 2014, FxCodex Laboratory
0 11:09:37.730 MySQL-002 EURUSD,H1: Host: , User: , Database:
0 11:09:37.730 MySQL-002 EURUSD,H1: Connecting...
0 11:09:37.741 MySQL-002 EURUSD,H1: Connected! DBID#0
0 11:09:37.742 MySQL-002 EURUSD,H1: Table `table` cannot be created. Error: Aucune base n'a ?t? s?lectionn?e
0 11:09:37.742 MySQL-002 EURUSD,H1: Disconnected. Script done!
0 11:09:37.742 MySQL-002 EURUSD,H1: uninit reason 0
0 11:09:37.743 Script MySQL-002 EURUSD,H1: removed
Hello Eugeniy,
Thank you for the links.
At first I used your code to connect to my database (I was using mySql Server in case it is useful). And I could see the table. Then I changed the table's name at your MySQL-002 Script (as you can see below) and thought it seemed to work it wouldn't create my table. Now I'm using WampServer and I get:
0 11:09:37.579 Script MySQL-002 EURUSD,H1: loaded successfully
0 11:09:37.730 MySQL-002 EURUSD,H1: initialized
0 11:09:37.730 MySQL-002 EURUSD,H1: MQLMySQL v2.0 Demo Copyright © 2014, FxCodex Laboratory
0 11:09:37.730 MySQL-002 EURUSD,H1: Host: , User: , Database:
0 11:09:37.730 MySQL-002 EURUSD,H1: Connecting...
0 11:09:37.741 MySQL-002 EURUSD,H1: Connected! DBID#0
0 11:09:37.742 MySQL-002 EURUSD,H1: Table `table` cannot be created. Error: Aucune base n'a ?t? s?lectionn?e
0 11:09:37.742 MySQL-002 EURUSD,H1: Disconnected. Script done!
0 11:09:37.742 MySQL-002 EURUSD,H1: uninit reason 0
0 11:09:37.743 Script MySQL-002 EURUSD,H1: removed
Based on error I see from your log: 0 11:09:37.742 MySQL-002 EURUSD,H1: Table `table` cannot be created.
you are uses name "table" which is keyword of mysql database and cannot be used as table name, try to change to for example to "table1" just to check is it works.
or possible the database was not selected or was not set. you can execute command "USE database_name" right after connection, where the database_name is the name of your database.
for example if my database is "mysql":
DB = MySqlConnect(Host, User, Password, Database, Port, Socket, ClientFlag);
if (DB == -1) { Print ("Connection failed! Error: "+MySqlErrorDescription); } else { Print ("Connected! DBID#",DB);}
MySqlExecute(DB, "USE mysql");