rendanic / rendanic.ansible_oracle / 4.0.0 / module / oracle_sql Execute arbitrary sql | "added in version" 2.1.0.0 of rendanic.ansible_oracle" Authors: Mikael Sandström, oravirt@gmail.com, @oravirtrendanic.ansible_oracle.oracle_sql (4.0.0) — module
Install with ansible-galaxy collection install rendanic.ansible_oracle:==4.0.0
collections: - name: rendanic.ansible_oracle version: 4.0.0
Execute arbitrary sql against an Oracle database
# Execute arbitrary sql - oracle_sql: username: "{{ user }}" password: "{{ password }}" service_name: one.world sql: 'select username from dba_users'
# Execute arbitrary script1 - oracle_sql: username: "{{ user }}" password: "{{ password }}" service_name: one.world script: /u01/scripts/create-all-the-procedures.sql
# Execute arbitrary script2 - oracle_sql: username: "{{ user }}" password: "{{ password }}" service_name: one.world script: /u01/scripts/create-tables-and-insert-default-values.sql
sql: description: The sql you want to execute required: false port: default: 1521 description: The listener port to connect to the database required: false script: description: The script you want to execute. Doesn't handle selects required: false hostname: aliases: - host default: localhost description: The host of the database required: false password: aliases: - pw default: None description: The password to connect to the database required: false username: aliases: - un default: None description: The database username to connect to the database required: false service_name: aliases: - sn default: database_name description: The service_name to connect to the database required: false