Powershell connector with property having space in name

Hi All,

I want to read some data from Service now using powershell conenctor.

I created defination file which has one propery in schema with space in name.

Schema propery name is IT Application OwnerName

When I check for defination file I get error, my defination file works fine if I remove this property.

My queation is powershell connector support property with space in it.

If yes then how can be this resolved.

Please see my PS defination file at below location.

https://1drv.ms/t/s!At2ViqLAc9Hp0yvd0qIr9O2a-zJf?e=VkQRwi 

Thank you in advance.

Kind Regards,

Dnyandev

  • Workaround add alias property to the posh result object w/o spaces
    Add-Member -InputObject $Outputvalue -MemberType NoteProperty -Name 'ITApplicationOwnerName' -Value $Outputvalue.'IT Application OwnerName'

    I think the definition XML it does not support spaces.
    Did you try single quotes or braces? Path="'IT Application OwnerName'" or  Path="{IT Application OwnerName}" />
    Personally I wouldn't use spaces, just to keep things simple.

  • Hi Niels,

    Thank you for hint.

    Adding alias propery to the Powershell result soleved issue.