How to execute a SQL Script ( MS SQL 2014 SP2 ) by Ansible

Hello Guys,

I have copied a script on MS SQL server on c:\temp\always-on.sql

I’m wondering how to have it executed by Ansible, win_shell module? or is there any specialized module for MSSQL for Ansible?

Kindly assist

Thanks
Ameya Agashe

There is no specific mssql query module part of ansible itself, but a 3rd party module does exist for this purpose:
https://github.com/melmorabity/ansible-mssql-query
If you can, report on its usability.

Dick

Sounds good, I shall certainly try and provide feedback here.

Many thanks

Ameya Agashe