On Monday, February 26, 2018 at 9:46:50 AM UTC-6, Kai Stian Olstad wrote:
>
> On Monday, 26 February 2018 07.15.27 CET Raja Shekar wrote: 
> >   - debug: var=groups_out.stdout_lines 
> > 
> >   - name: Update the Client Schema 
> >     shell: source ~/.bash_profile && sqlplus -S '{{ item.1.groups_out 
> }}/{{ 
> > item.2.groups_out }}@{{ item.4.groups_out }}' 
> > @"roles/oracle-sql/files/Scripts/client_hotfix.sql" {{ item.0.groups_out 
> }} 
> >     sudo: no 
> >     with_items: "{{ groups_out.stdout_lines }}" 
> > 
> > 
> > Failing with below error message 
> > 
> > fatal: [10.202.98.198]: FAILED! => {"failed": true, "msg": "The task 
> > includes an option with an undefined variable. The error was: 'unicode 
> > object' has no attribute 'groups_out'\n\nThe error appears to have been 
> in 
> > '/etc/ansible/playbooks/database/roles/oracle-sql/tasks/main.yml': line 
> 57, 
> > column 5, but may\nbe elsewhere in the file depending on the exact 
> syntax 
> > problem.\n\nThe offending line appears to be:\n\n\n  - name: Update the 
> > Schema info\n    ^ here\n\nexception type: <class 
> > 'ansible.errors.AnsibleUndefinedVariable'>\nexception: 'unicode object' 
> has 
> > no attribute 'groups_out'"} 
>
> It says item.X.groups_out do not exist. 
> You would need to show you the content of groups_out.stdout_lines 
>
> g 
> -- 
> Kai Stian Olstad 
>

Hello Kai, 

Thanks for looking into this. here is the content of 
"groups_out.stdout_lines"

    "groups_out.stdout_lines": [
        
"\"DB_SCHEMA\",\"SYSTEM_USER\",\"SYSTEM_PASSWORD\",\"TNS_NAME\",\"TNS_DESCRIPTION\"",
        
"\"Client_Schema1\",\"user\"password\",\"TNS_NAME\",\"(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=SANDBOX1)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)))\"",
        
"\"Client_Schema2\",\"user\"password\",\"TNS_NAME\",\"(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=SANDBOX1)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)))\"",
        
"\"Client_Schema3\",\"user\"password\",\"TNS_NAME\",\"(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=SANDBOX1)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)))\"",
        
"\"Client_Schema4\",\"user\"password\",\"TNS_NAME\",\"(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=SANDBOX1)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)))\"",
        
"\"Client_Schema5\",\"user\"password\",\"TNS_NAME\",\"(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=SANDBOX1)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)))\"",
        
"\"Client_Schema6\",\"user\"password\",\"TNS_NAME\",\"(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=SANDBOX1)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)))\"",
    ]
} 

-- 
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 ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/e24215d2-fe0a-48f0-86d3-c3530ed03ed3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to