I'm trying to output data to a table containing a field named "user". User being a reserved keyword in SQL, it throws the following error:
2018-05-01 10:15:09.378 +0200 [QuartzScheduler_Worker-10] INFO com.splunk.dbx.connector.logger.AuditLogger - operation=dboutput connection_name=aaa stanza_name=bbb state=error sql='INSERT INTO "ccc"."dbo"."ddd" (eee,**user**,fff,ggg) values (?,?,?,?)' message='Incorrect syntax near the keyword 'user'.'
Is there any way to workaround this, such as forcing it to be called enclosed by brackets
sql='INSERT INTO "ccc"."dbo"."ddd" ([eee],**[user]**,[fff],[ggg]) values (?,?,?,?)'
Answering my own question...
I was able to work around this by enclosing my user (to [user]) field in the customized_mappings stanza in db_outputs.conf and restarting splunk.
View solution in original post