DB-configCheck mit "Fehlern"

Begonnen von Kaspi, 11 Januar 2018, 11:12:24

Vorheriges Thema - Nächstes Thema

Kaspi

Hi

Habe folgende "Fehler" angezeigt bekommen:

Result of table 'history' check

Column width set in DB /opt/fhem/fhem.db.history: 'DEVICE' = 32, 'TYPE' = 32, 'EVENT' = 512, 'READING' = 32, 'VALUE' = 32, 'UNIT' = 32
Column width used by myDbLog: 'DEVICE' = 64, 'TYPE' = 64, 'EVENT' = 512, 'READING' = 64, 'VALUE' = 128, 'UNIT' = 32
Recommendation: WARNING - The relation between column width in table history and the field width used by device myDbLog should be equal but it differs. The field width used by the module can be adjusted by attributes 'colEvent', 'colReading', 'colValue'. Because you use SQLite this is only a warning. Normally the database can handle these differences.

Result of table 'current' check

Column width set in DB /opt/fhem/fhem.db.current: 'DEVICE' = 32, 'TYPE' = 32, 'EVENT' = 512, 'READING' = 32, 'VALUE' = 32, 'UNIT' = 32
Column width used by myDbLog: 'DEVICE' = 64, 'TYPE' = 64, 'EVENT' = 512, 'READING' = 64, 'VALUE' = 128, 'UNIT' = 32
Recommendation: WARNING - The relation between column width in table current and the field width used by device myDbLog should be equal but it differs. The field width used by the module can be adjusted by attributes 'colEvent', 'colReading', 'colValue'. Because you use SQLite this is only a warning. Normally the database can handle these differences.

kann ich nachträglich "fhem.db.current" und "fhem.db.history" ändern?
Wie mache ich das?
Gehen Daten verloren?

Gruß

Kaspi  :)

DS_Starter

Hallo Kaspi,

für die Nutzer von SQLite habe ich bei diesen dargestellten Abweichungen lediglich eine WARNUNG ausgegeben.
Normalerweise kann SQLite damit umgehen und speichert das Feld auch dann wenn die Daten länger sind als definiert (zumindest mein Kenntnisstand).
Ist ja auch so erläutert ( "Because you use SQLite this is only a warning. Normally the database can handle these differences.").

Insofern gibt es keinen direkten Handlungsbedarf, aber man soll auf diesen Fakt hingewiesen sein damit es im Hinterkopf ist.
Eine nachträgliche Änderung der Feldbreite kenne ich bei SQLite nicht. Man kann im Modul mit den genannten Attributen die Anzahl der einzelnen Character pro Feld den tatsächlichen Gegebenheiten anpassen/beschränken wenn man das möchte/benötigt.

Grüße
Heiko
Proxmox+Debian+MariaDB, PV: SMA, Victron MPII+Pylontech+CerboGX
Maintainer: SSCam, SSChatBot, SSCal, SSFile, DbLog/DbRep, Log2Syslog, SolarForecast,Watches, Dashboard, PylonLowVoltage
Kaffeekasse: https://www.paypal.me/HMaaz
Contrib: https://svn.fhem.de/trac/browser/trunk/fhem/contrib/DS_Starter