Commit Graph

10 Commits

Author SHA1 Message Date
Fred Z b18a7062ca Wraps method 'pymysql…execute()', adds 'autocommit' 2018-08-03 18:23:26 +02:00
Fred Z 5d5646ca9d Strengthens the Db() class
- Adds 2 'connection' attributes 'self.cnx' & 'self.cursor'
- Adds some tests
- TODO : Find how to test if connection is broken
- Renames 'cnx()' method to 'start_connexion()'
2018-08-03 18:11:08 +02:00
Fred Z 7d1f4418db Adds 'db_summary()' method
To lighten and improve the __init__
Now it can be re-called after the create-DB script
Exports messages template in 'config.py'
PyMysql seem not to accept 'CREATE TABLE IF NOT EXIST'
2018-08-03 00:41:17 +02:00
Fred Z 192e18d8e0 Refactors DB access 2018-08-02 20:00:30 +02:00
Fred Z 3ffbcfa208 Adds messaging & stats features #4 2018-08-02 11:20:51 +02:00
Fred Z ca821728ae Packs database script in a class
Adds little tests
2018-07-30 07:25:21 +02:00
Fred Z cff82380b8 Exports config in a new file 'config.py' 2018-07-27 22:27:42 +02:00
Fred Z 1c868d21c0 Adds test wrong file to 'sql_create_db()' 2018-07-27 22:14:53 +02:00
Fred Z c392d1772d Creates DB if not exist #4 2018-07-27 18:46:33 +02:00
Fred Z 80ace05a4a Adds the first PyMySQL to DB interaction 2018-07-26 19:42:11 +02:00