I have a project where I need to calculate the energy of a PV_system.
I have uploaded the data in the InfluxDB database (locally).
I want to use a loop to calculate the daily energy during one year. Unfortunately I can’t use the function now() in my code, because the date of the measurement is in the past. But I know the beginning and can therefore query the energy in one day.**
from influxdb import InfluxDBClient
import matplotlib.pyplot as plt
import numpy
from datetime import datetime
import select
response = influxdb_client.query('select difference(E_PV) from PV_Energy_2019_2020 where time >=
1574536506 + 24h', database='Projektarbeit_PV_Anlage')
**
My question is how can I add the shift function to the query so that I can shift the time?
I want that the second run start on the second day and not the first.