I am getting below error when trying to execute an Insert mssql query, the row is getting inserted but somehow failing with this
Statement not executed or executed statement has no resultset
this is my playbook
name: Insert into sql server
community.general.mssql_script:
login_user: ‘username’
login_password: “{{ mssql_login_password }}”
login_host: “{{ mssql_server }}”
login_port: “{{ mssql_port }}”
db: testdb
script: “insert into [Test].[RP].[ApplicationCategory] values (NULL,NULL,‘xyz’,‘repo’,NULL,getdate(),1,NULL,‘xyz’,NULL,‘xyz’)”
tags: jenkinsjob
I think I fixed the issue I added ;Select 1 this at the end of the insert statement and that fixed the issue when running mssql module to run an Insert query through jenkins console