[JDBC/MariaDB] Persistence of only actual state?

Tags: #<Tag:0x00007f6169419ac0> #<Tag:0x00007f6169419980> #<Tag:0x00007f61694198b8>


I’m using mariadb as persistence unit via jdbc.
Now every change of an item state gets stored as new row in the item’s database table.
Is there an easy way to store only the actual state of an item in the item’s sql table?

Thanks, Florian

I doubt it since there is no config option that would limit this: https://www.openhab.org/addons/persistence/jdbc/#configuration

If you only want the current state to be persisted you can use mapDB (this is what it does) https://www.openhab.org/addons/persistence/mapdb/