# Checking error fetching tag history to clear logs window

**URL:** <https://forum.inductiveautomation.com/t/checking-error-fetching-tag-history-to-clear-logs-window/106788>\
**Category:** Ignition\
**Tags:** perspective\
**Created:** [May 28, 2025, 7:38pm UTC](https://forum.inductiveautomation.com/t/checking-error-fetching-tag-history-to-clear-logs-window/106788 "2025-05-28T19:38:51Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![RENATO\_DUENAS](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/renato_duenas/32/40767_2.png) [@RENATO\_DUENAS](https://forum.inductiveautomation.com/u/RENATO_DUENAS)\
**Post date:** [May 28, 2025, 7:38pm UTC](https://forum.inductiveautomation.com/t/checking-error-fetching-tag-history-to-clear-logs-window/106788/1 "2025-05-28T19:38:51Z")

</div>

Have you experienced this type of error. I am trying to clean my logs windows from any errors, and the following is one of the most common.

```python
java.lang.IllegalArgumentException: Numeric values must be finite, but was NaN
at com.inductiveautomation.ignition.common.gson.stream.JsonWriter.value(JsonWriter.java:524)
at com.inductiveautomation.ignition.common.StreamingDatasetJsonWriter.write(StreamingDatasetJsonWriter.java:64)
at com.inductiveautomation.ignition.gateway.sqltags.history.query.HistoryWriter.commitRows(HistoryWriter.java:384)
at com.inductiveautomation.ignition.gateway.sqltags.history.query.HistoryWriter.finalizeWriter(HistoryWriter.java:283)
at com.inductiveautomation.ignition.gateway.sqltags.history.query.HistoryWriter.execute(HistoryWriter.java:235)
at com.inductiveautomation.ignition.gateway.sqltags.history.TagHistoryManagerImpl.queryHistory(TagHistoryManagerImpl.java:572)
at com.inductiveautomation.ignition.gateway.tags.model.ProjectDefaultTagManagerFacade.queryHistory(ProjectDefaultTagManagerFacade.java:440)
at com.inductiveautomation.perspective.gateway.components.PowerChartModelDelegate$TagHistoryFetch.fetch(PowerChartModelDelegate.java:252)
at com.inductiveautomation.perspective.gateway.comm.FetchableCacheImpl.lambda$fetch$0(FetchableCacheImpl.java:47)
at com.inductiveautomation.perspective.gateway.threading.BlockingWork.invokeBlockingTask(BlockingWork.java:34)
at com.inductiveautomation.perspective.gateway.comm.FetchableCacheImpl.fetch(FetchableCacheImpl.java:47)
at com.inductiveautomation.perspective.gateway.comm.Routes.handleFetch(Routes.java:2374)
at com.inductiveautomation.ignition.gateway.dataroutes.Route.service(Route.java:254)
at com.inductiveautomation.ignition.gateway.dataroutes.RouteGroupImpl.service(RouteGroupImpl.java:61)
at com.inductiveautomation.ignition.gateway.dataroutes.RouteGroupCollectionServlet.serviceInternal(RouteGroupCollectionServlet.java:59)
at com.inductiveautomation.ignition.gateway.dataroutes.AbstractRouteGroupServlet.service(AbstractRouteGroupServlet.java:38)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:590)
at org.eclipse.jetty.servlet.ServletHolder$NotAsync.service(ServletHolder.java:1410)
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:764)
at org.eclipse.jetty.servlet.ServletHandler$ChainEnd.doFilter(ServletHandler.java:1665)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:527)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:131)
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:578)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:122)
at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:223)
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1570 
at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:221)
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1384)
at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:176)
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:484)
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1543)
at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:174)
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1306)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:129)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:122)
at com.inductiveautomation.catapult.handlers.RemoteHostNameLookupHandler.handle(RemoteHostNameLookupHandler.java:121)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:122)
at org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandler.java:301)
at org.eclipse.jetty.server.handler.HandlerList.handle(HandlerList.java:51)
at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:141)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:122)
at org.eclipse.jetty.server.Server.handle(Server.java:563)
at org.eclipse.jetty.server.HttpChannel.lambda$handle$0(HttpChannel.java:505)
at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:762)
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:497)
at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:282)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:314)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:100)
at org.eclipse.jetty.io.SelectableChannelEndPoint$1.run(SelectableChannelEndPoint.java:53)
at org.eclipse.jetty.util.thread.strategy.AdaptiveExecutionStrategy.runTask(AdaptiveExecutionStrategy.java:416)
at org.eclipse.jetty.util.thread.strategy.AdaptiveExecutionStrategy.consumeTask(AdaptiveExecutionStrategy.java:385)
at org.eclipse.jetty.util.thread.strategy.AdaptiveExecutionStrategy.tryProduce(AdaptiveExecutionStrategy.java:272)
at org.eclipse.jetty.util.thread.strategy.AdaptiveExecutionStrategy.lambda$new$0(AdaptiveExecutionStrategy.java:140)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:411)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:969)
at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.doRunJob(QueuedThreadPool.java:1194)
at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1149)
at java.base/java.lang.Thread.run(Unknown Source)

```

From what I can see, the system expects a finite number, but it received a NaN instead. So, while it’s clear that the issue is caused by an invalid mathematical operation, my question is:

**How can I identify where this incorrect calculation is happening?**

Your feedback will be great!

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [May 28, 2025, 8:25pm UTC](https://forum.inductiveautomation.com/t/checking-error-fetching-tag-history-to-clear-logs-window/106788/2 "2025-05-28T20:25:50Z")

</div>

There might not _be_ much for you to do about it.

```python
java.lang.IllegalArgumentException: Numeric values must be finite, but was NaN
at com.inductiveautomation.ignition.common.gson.stream.JsonWriter.value(JsonWriter.java:524)
at com.inductiveautomation.ignition.common.StreamingDatasetJsonWriter.write(StreamingDatasetJsonWriter.java:64)
at com.inductiveautomation.ignition.gateway.sqltags.history.query.HistoryWriter.commitRows(HistoryWriter.java:384)
at com.inductiveautomation.ignition.gateway.sqltags.history.query.HistoryWriter.finalizeWriter(HistoryWriter.java:283)
at com.inductiveautomation.ignition.gateway.sqltags.history.query.HistoryWriter.execute(HistoryWriter.java:235)
at com.inductiveautomation.ignition.gateway.sqltags.history.TagHistoryManagerImpl.queryHistory(TagHistoryManagerImpl.java:572)
at com.inductiveautomation.ignition.gateway.tags.model.ProjectDefaultTagManagerFacade.queryHistory(ProjectDefaultTagManagerFacade.java:440)
at com.inductiveautomation.perspective.gateway.components.PowerChartModelDelegate$TagHistoryFetch.fetch(PowerChartModelDelegate.java:252)
at com.inductiveautomation.perspective.gateway.comm.FetchableCacheImpl.lambda$fetch$0(FetchableCacheImpl.java:47)
at com.inductiveautomation.perspective.gateway.threading.BlockingWork.invokeBlockingTask(BlockingWork.java:34)
at com.inductiveautomation.perspective.gateway.comm.FetchableCacheImpl.fetch(FetchableCacheImpl.java:47)
at com.inductiveautomation.perspective.gateway.comm.Routes.handleFetch(Routes.java:2374)
at com.inductiveautomation.ignition.gateway.dataroutes.Route.service(Route.java:254)
at com.inductiveautomation.ignition.gateway.dataroutes.RouteGroupImpl.service(RouteGroupImpl.java:61)
at com.inductiveautomation.ignition.gateway.dataroutes.RouteGroupCollectionServlet.serviceInternal(RouteGroupCollectionServlet.java:59)
at com.inductiveautomation.ignition.gateway.dataroutes.AbstractRouteGroupServlet.service(AbstractRouteGroupServlet.java:38)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:590)

```

There's a power chart in a Perspective session that's running a history query; that history query is return JSON data and that's where the NaN is causing issues.

---

<div class="post-metadata">

**Author:** ![RENATO\_DUENAS](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/renato_duenas/32/40767_2.png) [@RENATO\_DUENAS](https://forum.inductiveautomation.com/u/RENATO_DUENAS)\
**Post date:** [May 29, 2025, 2:36pm UTC](https://forum.inductiveautomation.com/t/checking-error-fetching-tag-history-to-clear-logs-window/106788/3 "2025-05-29T14:36:58Z")

</div>

Well, thanks for your response @paul-griffith.

Based on your response, I understand that if the history tables contain `NaN` values, and I query that data using a Power Chart, it may trigger the error I'm experiencing.

In the attached image, you can see the contents of my history tables, and I have two questions:

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/7/a/7a13de00ef16f4cc3f5d11ebcc88589202ef9539.png)

1. Could the `NaN` values be represented as `NULL` in the table? To test this, I queried a tag using a Power Chart in a session to try to reproduce the issue, but so far, I haven’t had any success.
2. Is there any other reason why the table `sqlt_data_1_2025_02` might have been dropped? It no longer appears in the history schema, and I’m confident that we didn’t delete it manually. I’ve attached a screenshot of the historical configuration for reference.

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/8/1/81075b720650a503e8193a4ba2fa4f839107f8aa.png)

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [May 29, 2025, 3:19pm UTC](https://forum.inductiveautomation.com/t/checking-error-fetching-tag-history-to-clear-logs-window/106788/4 "2025-05-29T15:19:09Z")

</div>

I would recommend contacting our support department officially, so you can get faster and more in depth help. All I can offer is broad guesses.
