[influxdb] FieldTypeConflictException: "..." is type integer, already exists as type float
See original GitHub issueAs part of migrating to OH3 I’ve added my influxdb persistence. For some reason, I’m now getting this error. I get this across multiple items, not just the one below. I could just purge these values from the database and let it create new as a workaround, but I’d rather not lose the historical data. Not sure why it’s writing as an integer now and not a float as before.
2020-11-14 20:32:37.956 [ERROR] [org.influxdb.impl.BatchProcessor ] - Batch could not be sent. Data will be lost
org.influxdb.InfluxDBException$FieldTypeConflictException: partial write: field type conflict: input field "value" on measurement "ZWave_DownstairsHallwayMotionSensor_BinarySensor" is type integer, already exists as type float dropped=1
at org.influxdb.InfluxDBException.buildExceptionFromErrorMessage(InfluxDBException.java:144) ~[bundleFile:?]
at org.influxdb.InfluxDBException.buildExceptionForErrorState(InfluxDBException.java:173) ~[bundleFile:?]
at org.influxdb.impl.InfluxDBImpl.execute(InfluxDBImpl.java:827) ~[bundleFile:?]
at org.influxdb.impl.InfluxDBImpl.write(InfluxDBImpl.java:460) ~[bundleFile:?]
at org.influxdb.impl.OneShotBatchWriter.write(OneShotBatchWriter.java:22) ~[bundleFile:?]
at org.influxdb.impl.BatchProcessor.write(BatchProcessor.java:340) [bundleFile:?]
at org.influxdb.impl.BatchProcessor$1.run(BatchProcessor.java:287) [bundleFile:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) [?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304) [?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
at java.lang.Thread.run(Thread.java:834) [?:?]
Issue Analytics
- State:
- Created 3 years ago
- Comments:28 (12 by maintainers)
Top Results From Across the Web
How to solve type conflicts - InfluxDB 2
Hi, I'm using the influxdb-php lib to read from and write to influx. ... on measurement "temp" is type integer, already exists as...
Read more >InfluxDB Error "field type conflict: input field value on ...
InfluxDB Error "field type conflict: input field value on measurement is type integer, already exists as type float dropped=1".
Read more >influxdb insert error: type float, already exists as type integer ...
As described in the influxdb 1.8 docs, changing a field type is complicated. A ridiculously simple solution is to just change its name...
Read more >When ThingWorx Platform is using InfluxDB ... - PTC
InfluxDBException$FieldTypeConflictException: partial write: field ... Pump1" is type integer, already exists as type float dropped=1 at ...
Read more >Influxdb 2.0 Error Data Type - General - Node-RED Forum
... to database: partial write: field type conflict: input field "ITE06_H" on measurement "ITE06" is type integer, already exists as type float dropped=1"}....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
On one of my OH instances I also ran into this issue with some
Switch
items. So I wrote a little Bash script to fix it for several items to prevent errors and tedious work 😉 :Just replace
Room1_Motion
etc. with your own items that have this issue. Make sure you have a backup in case something goes wrong. 💾I must admit, I encountered the same problem and worked around it, instead of raising an issue. I changed the type of my historic data to integer by storing it to a temporary measurement: