Was wondering if it’s possible to add missing data to a energy entity with mariadb database?
For example, the entity has become unknown from the 2nd till the 4th and in the database there are no data to edit for those dates. Would like to manually populate/add data on those dates if it’s possible.
was doing some research on how to get this done but didn’t find many solutions on others doing smth similar. I have taken a look at the database with phpMyAdmin and the problem I’m facing is how to add a record properly.
I can see that the states would keep incrementing and increasing the state_id, I don’t think I’m able to put in any number since it goes up in order. Was wondering how could i use the right state_id, and how the context_id work
State Id is the identity column and will be auto assigned by the database when you insert a record. In other words you don’t provide it in your insert statement.
Have tried this and it added the missing records into the entity, which looks like it works. Not too sure if it has or would cause any other issues in the database
I edit stuff when I need to remove bad sensor values, etc. No problems.
But one area I don’t know and/or use are the statistics. I do not know if these changes or new records get picked up by statistics and/or if there is something that needs to be manually triggered to cause it to recalculate.