Rename stats to statistics (BC) (#10551)

This commit is contained in:
andig 2023-10-29 12:29:53 +01:00 • committed by GitHub
parent 4bddf556df
commit da68bc03b5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 15 additions and 14 deletions

24
tests/statistics.sql Normal file
View file

@ -0,0 +1,24 @@
DROP TABLE IF EXISTS `sessions`;
CREATE TABLE `sessions` (
`id` integer,
`created` datetime,
`finished` datetime,
`loadpoint` text,
`identifier` text,
`vehicle` text,
`meter_start_kwh` real,
`meter_end_kwh` real,
`charged_kwh` real,
`odometer` real,
`solar_percentage` real,
`price` real,
`price_per_kwh` real,
`co2_per_kwh` real,
`charge_duration` integer,
PRIMARY KEY (`id`)
);
INSERT INTO `sessions` VALUES (1, datetime('now', '-1 day'),datetime('now', '-0 day'),'Carport',NULL,'e-Golf',NULL,NULL,40,NULL, 50, 8,0.2,10,null);
INSERT INTO `sessions` VALUES (2, datetime('now', '-11 day'),datetime('now', '-10 day'),'Carport',NULL,'e-Golf',NULL,NULL,10,NULL,100, 1,0.1, 0,null);
INSERT INTO `sessions` VALUES (3, datetime('now', '-101 day'),datetime('now', '-100 day'),'Carport',NULL,'e-Golf',NULL,NULL,50,NULL, 0,15,0.3,20,null);
INSERT INTO `sessions` VALUES (4, datetime('now', '-901 day'),datetime('now', '-900 day'),'Carport',NULL,'e-Golf',NULL,NULL,40,NULL,100, 3,0.1, 0,null);