pymssql-2.2.7
I am just trying to make a sql connection by checking the connectivity to
sql server, if this is successfully I have to get some select and update
statements working
this is my playbook
---
- name: Execute sql commands
hosts: localhost
gather_facts: false
become: true
user: root
vars_files:
- group_vars/mssqlpass.yml
tasks:
- name: Check DB connection
community.general.mssql_script:
login_user: "{{ mssql_login_user }}"
login_password: "{{ mssql_login_password }}"
login_host: "{{ mssql_server }}"
login_port: "{{ mssql_port }}"
db: dbname
script: "SELECT *"
On Monday, July 3, 2023 at 1:18:28 PM UTC-7 Abhijeet Kasurde wrote:
> Hi Narmada,
>
> Could you please provide more context like playbooks used, collections
> used, modules used, ultimate aim to achieve etc? Without this information,
> it is really difficult to debug.
>
> On Mon, Jul 3, 2023 at 1:07 PM Narmada Karthika <[email protected]>
> wrote:
>
>> Any idea about this error, the username and password are correct those
>> are dbo creds. I am able to connect through ssms with the same creds but
>> not working through ansible
>> also I don't see @sysconfdir@/freetds.conf / ${HOME}/.freetds.conf" on my
>> linux node...
>>
>>
>> TASK [Check DB connection]
>> *********************************************************************************************************************************************
>> fatal: [localhost]: FAILED! => {"changed": false, "msg": "unable to
>> connect, check login_user and login_password are correct, or alternatively
>> check your @sysconfdir@/freetds.conf / ${HOME}/.freetds.conf"}
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Ansible Project" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected].
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/ansible-project/450d5ff6-1aba-45e3-ab89-555225d3db46n%40googlegroups.com
>>
>> <https://groups.google.com/d/msgid/ansible-project/450d5ff6-1aba-45e3-ab89-555225d3db46n%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>
>
> --
> Thanks,
> Abhijeet Kasurde
>
--
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/3b2e4022-3029-4c46-8056-95aff41c4122n%40googlegroups.com.