VzPython

From BITPlan Wiki
Jump to navigation Jump to search
show tables;
+------------------------+
| Tables_in_volkszaehler |
+------------------------+
| aggregate              |
| daily                  |
| data                   |
+------------------------+
MariaDB [volkszaehler]> describe aggregate;
+------------+-------------+------+-----+---------+----------------+
| Field      | Type        | Null | Key | Default | Extra          |
+------------+-------------+------+-----+---------+----------------+
| id         | int(11)     | NO   | PRI | NULL    | auto_increment |
| channel_id | int(11)     | YES  | MUL | NULL    |                |
| type       | smallint(6) | NO   |     | NULL    |                |
| timestamp  | bigint(20)  | NO   |     | NULL    |                |
| value      | double      | NO   |     | NULL    |                |
| count      | int(11)     | NO   |     | NULL    |                |
+------------+-------------+------+-----+---------+----------------+


MariaDB [volkszaehler]> describe daily;
+-----------+--------------+------+-----+---------+-------+
| Field     | Type         | Null | Key | Default | Extra |
+-----------+--------------+------+-----+---------+-------+
| from_date | varchar(29)  | YES  |     | NULL    |       |
| id        | int(11)      | NO   |     | 0       |       |
| diff      | varchar(62)  | YES  |     | NULL    |       |
| type      | varchar(255) | NO   |     | NULL    |       |
| value     | longtext     | NO   |     | NULL    |       |
+-----------+--------------+------+-----+---------+-------+

MariaDB [volkszaehler]> describe data;
+------------+------------+------+-----+---------+----------------+
| Field      | Type       | Null | Key | Default | Extra          |
+------------+------------+------+-----+---------+----------------+
| id         | int(11)    | NO   | PRI | NULL    | auto_increment |
| channel_id | int(11)    | YES  | MUL | NULL    |                |
| timestamp  | bigint(20) | NO   | MUL | NULL    |                |
| value      | double     | NO   |     | NULL    |                |
+------------+------------+------+-----+---------+----------------+