I’m currently having an issue getting an issue with SQL historian not creating tables in MSSQL database. After creating the database connection and adding the historian, the following error is shown in the logs.
ERROR
TagHistoryDatasourceSink
05Feb2026 14:08:58
Data sink 'ignition_sql' has encountered critical failure.
java.lang.IllegalStateException: Initialization of tag history datasource sink has failed!
at com.inductiveautomation.sqlhistorian.gateway.storage.TagHistoryDatasourceSink.onInitialize(TagHistoryDatasourceSink.java:241)
at com.inductiveautomation.ignition.gateway.storeforward.sinks.AbstractSink.initialize(AbstractSink.java:138)
at com.inductiveautomation.ignition.gateway.storeforward.sinks.AbstractDatasourceSink$DatasourceConnectionListener.onStatusChanged(AbstractDatasourceSink.java:281)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceImpl.lambda$notifyListeners$3(DatasourceImpl.java:614)
at java.base/java.util.ArrayList.forEach(Unknown Source)
at java.base/java.util.Collections$SynchronizedCollection.forEach(Unknown Source)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceImpl.notifyListeners(DatasourceImpl.java:614)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceImpl.setStatus(DatasourceImpl.java:508)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceImpl.runTest(DatasourceImpl.java:333)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceManagerImpl$FaultedDatasourceRetryer.lambda$newRetryRunnable$0(DatasourceManagerImpl.java:1174)
at com.inductiveautomation.ignition.common.execution.impl.BasicExecutionEngine$TrackedTask.run(BasicExecutionEngine.java:593)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.base/java.util.concurrent.FutureTask.runAndReset(Unknown Source)
at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.base/java.lang.Thread.run(Unknown Source)
Caused by: java.lang.Exception: Error running query: CREATE TABLE sqlth_drv (id int NOT NULL AUTO_INCREMENT,name varchar(255),provider varchar(255),PRIMARY KEY (id))
at com.inductiveautomation.ignition.gateway.db.schema.DBTableSchema.executeCommandSet(DBTableSchema.java:139)
at com.inductiveautomation.ignition.gateway.db.schema.DBTableSchema.createTable(DBTableSchema.java:108)
at com.inductiveautomation.ignition.gateway.db.schema.DBTableSchema.verifyAndUpdate(DBTableSchema.java:91)
at com.inductiveautomation.sqlhistorian.gateway.storage.TagHistoryDatasourceSink.checkTables(TagHistoryDatasourceSink.java:1657)
at com.inductiveautomation.sqlhistorian.gateway.storage.TagHistoryDatasourceSink.onInitialize(TagHistoryDatasourceSink.java:230)
... 16 common frames omitted
Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Incorrect syntax near 'AUTO_INCREMENT'.
at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:278)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.getNextResult(SQLServerStatement.java:1788)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.doExecuteStatement(SQLServerStatement.java:975)
at com.microsoft.sqlserver.jdbc.SQLServerStatement$StmtExecCmd.doExecute(SQLServerStatement.java:869)
at com.microsoft.sqlserver.jdbc.TDSCommand.execute(IOBuffer.java:7825)
at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(SQLServerConnection.java:4828)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeCommand(SQLServerStatement.java:321)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeStatement(SQLServerStatement.java:253)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeUpdate(SQLServerStatement.java:808)
at org.apache.commons.dbcp2.DelegatingStatement.executeUpdate(DelegatingStatement.java:331)
at org.apache.commons.dbcp2.DelegatingStatement.executeUpdate(DelegatingStatement.java:331)
at com.inductiveautomation.ignition.gateway.datasource.DelegatingStatement.executeUpdate(DelegatingStatement.java:80)
at com.inductiveautomation.ignition.gateway.datasource.SRConnectionWrapper$SRStatement.executeUpdate(SRConnectionWrapper.java:867)
at com.inductiveautomation.ignition.gateway.db.schema.DBTableSchema.executeCommandSet(DBTableSchema.java:137)
... 20 common frames omitted
Based on this line from the error message…
Caused by: java.lang.Exception: Error running query: CREATE TABLE sqlth_drv (id int NOT NULL AUTO_INCREMENT,name varchar(255),provider varchar(255),PRIMARY KEY (id))
I’m lead to believe the MSSQL driver is not using the MSSQL translator. When I navigate to Connections>Databases>Settings, the “Default Translator” is listed as MSSQL, but the command AUTO_INCREMENT that is causing the syntax error is not used in the MSSQL translator, only the other translators.
Most recently, I tried the following to correct this issue thinking it would be as close as I could get to a clean install of MSSQL drivers without reinstalling Ignition entirely...
Delete historian and database from gateway
Restart gateway
Disable MSSQL module
Restart gateway
Delete MSSQL module
Restart gateway
Install MSSQL module
Restart gateway
and the issue still persist. I've restored this gateway backup from a production environment to a local gateway for troubleshooting, so I have the flexibility to try most troubleshooting options. Gateway version is 8.3.2 but I have also tried to solve this on 8.3.3 as well with no luck. Any suggestions are greatly appreciated!
Do you have a copy of your logs you can share/look through?
Particularly for gateway.Database messages that talk about a translator, such as: Updating database connection '{}' to use new definition of translator '{}' or "Could not find db translator for connection '{}'", name or similar.
I found the issue and it is shockingly simple considering how much time I spent troubleshooting this… This post lead me to editing the translators in search of double quotes, but I realized that there was an option to “Enable” on the context menu. As it turns out, none of my translators were enabled for some reason. I have enabled all of them and it seems like my problem is resolved.
Viewing the logs, I’m not sure if I could have identified this issue based on the error text, and there is also no indication on the translator settings screen of the enable/disable status as there is for most other configurable items, but definitely something that should have been realized sooner. I think the clearest indicator was no options being shown when trying to select a new default translator and having no options listed in the dropdown menu (shown in original body of this reply). Hopefully this can help someone else who is banging their head against the wall with this issue in the future!
The warnings/error/info that all occur at 19:39:50 are all occurring as a group a couple of times a day. I think the errors at 14:35:36 occur when I disable and reenable my database connection and is followed by the TagHistoryDataSink error.
One thing that I failed to mention in my original post is that when I go to database settings and edit the MSSQL driver, there are no options in the dropdown for Default Translator as shown below.
The full contents of Unable to create default db translator resource. is…
WARN
Database
05Feb2026 19:39:50
Unable to create default db translator resource.
com.inductiveautomation.ignition.common.resourcecollection.PushConflictException: CREATE illegal, 'ResourceId{resourcePath=ignition/database-translator/POSTGRES, collectionName=core}' already exists.
at com.inductiveautomation.ignition.gateway.resourcecollection.ResourceCollectionManagerImpl$AtomicPushValidationHandler.throwIfInvalid(ResourceCollectionManagerImpl.java:739)
at com.inductiveautomation.ignition.gateway.resourcecollection.ResourceCollectionManagerImpl.push(ResourceCollectionManagerImpl.java:1149)
at com.inductiveautomation.ignition.gateway.config.ConfigurationManagerImpl.push(ConfigurationManagerImpl.java:323)
at com.inductiveautomation.ignition.gateway.resourcecollection.ResourceCollectionManager.push(ResourceCollectionManager.java:319)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceManagerImpl$TranslatorHandler.createDefaultTranslator(DatasourceManagerImpl.java:1105)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceManagerImpl$TranslatorHandler.lambda$getOrCreate$4(DatasourceManagerImpl.java:1088)
at java.base/java.util.Optional.orElseGet(Unknown Source)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceManagerImpl$TranslatorHandler.getOrCreate(DatasourceManagerImpl.java:1088)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceManagerImpl.seedTranslatorsAndDrivers(DatasourceManagerImpl.java:702)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceManagerImpl.onStartup(DatasourceManagerImpl.java:461)
at com.inductiveautomation.ignition.common.lifecycle.AbstractLifecycle.startup(AbstractLifecycle.java:19)
at com.inductiveautomation.ignition.gateway.IgnitionGateway.startupInternal(IgnitionGateway.java:1320)
at com.inductiveautomation.ignition.gateway.redundancy.RedundancyManagerImpl.startup(RedundancyManagerImpl.java:352)
at com.inductiveautomation.ignition.gateway.IgnitionGateway.initRedundancy(IgnitionGateway.java:814)
at com.inductiveautomation.ignition.gateway.IgnitionGateway.lambda$initInternal$1(IgnitionGateway.java:736)
at com.inductiveautomation.ignition.common.execution.impl.BasicExecutionEngine$ThrowableCatchingRunnable.run(BasicExecutionEngine.java:550)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.base/java.lang.Thread.run(Unknown Source)
and the contents of Error seeding Oracle JDBC driver. is…
ERROR
Database
05Feb2026 19:39:50
Error seeding Oracle JDBC Driver.
com.inductiveautomation.ignition.common.resourcecollection.PushConflictException: CREATE illegal, 'ResourceId{resourcePath=ignition/database-driver/Oracle Database, collectionName=core}' already exists.
at com.inductiveautomation.ignition.gateway.resourcecollection.ResourceCollectionManagerImpl$AtomicPushValidationHandler.throwIfInvalid(ResourceCollectionManagerImpl.java:739)
at com.inductiveautomation.ignition.gateway.resourcecollection.ResourceCollectionManagerImpl.push(ResourceCollectionManagerImpl.java:1149)
at com.inductiveautomation.ignition.gateway.config.ConfigurationManagerImpl.push(ConfigurationManagerImpl.java:323)
at com.inductiveautomation.ignition.gateway.resourcecollection.ResourceCollectionManager.push(ResourceCollectionManager.java:319)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceManagerImpl.ensureDriverExists(DatasourceManagerImpl.java:755)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceManagerImpl.seedTranslatorsAndDrivers(DatasourceManagerImpl.java:719)
at com.inductiveautomation.ignition.gateway.datasource.DatasourceManagerImpl.onStartup(DatasourceManagerImpl.java:461)
at com.inductiveautomation.ignition.common.lifecycle.AbstractLifecycle.startup(AbstractLifecycle.java:19)
at com.inductiveautomation.ignition.gateway.IgnitionGateway.startupInternal(IgnitionGateway.java:1320)
at com.inductiveautomation.ignition.gateway.redundancy.RedundancyManagerImpl.startup(RedundancyManagerImpl.java:352)
at com.inductiveautomation.ignition.gateway.IgnitionGateway.initRedundancy(IgnitionGateway.java:814)
at com.inductiveautomation.ignition.gateway.IgnitionGateway.lambda$initInternal$1(IgnitionGateway.java:736)
at com.inductiveautomation.ignition.common.execution.impl.BasicExecutionEngine$ThrowableCatchingRunnable.run(BasicExecutionEngine.java:550)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.base/java.lang.Thread.run(Unknown Source)
I'm going to guess you selected the option to "Restore Disabled" when bringing a gateway backup forward at some point on 8.3.
This is a known issue that we've already ironed out, I believe in 8.3.4.
The short explanation is that because we moved everything to a standard configuration mechanism, the "enabled" state of a resource is enforced at a more global level, rather than each subsystem having to opt-in to it. For some things, though, like DB translators, that don't actually do anything independently, "disabled" is not a state with any real semantic meaning, and certainly it's not intentional that choosing to restore your system disabled would also prevent your translators from working. In 8.3.4 you can still manually disable translators (if that's something you actually wanted to do for some reason) but the process of restoring disabled will not affect them.