Skip to main content
added 11 characters in body
Source Link
Io-oI
  • 9.3k
  • 3
  • 15
  • 42

This worked for me, but I had to declare the results in a new variable, or PowerShell just kept breaking down the array into a single object...most frustrating. Thank

Thank you Microsoft for not considering the use case of JSON...insert seething sarcasm

$result = ConvertTo-Json -InputObject @($body) -compress

$result = ConvertTo-Json -InputObject @($body) -compress

This worked for me, but I had to declare the results in a new variable, or PowerShell just kept breaking down the array into a single object...most frustrating. Thank you Microsoft for not considering the use case of JSON...insert seething sarcasm

$result = ConvertTo-Json -InputObject @($body) -compress

This worked for me, but I had to declare the results in a new variable, or PowerShell just kept breaking down the array into a single object...most frustrating.

Thank you Microsoft for not considering the use case of JSON...insert seething sarcasm

$result = ConvertTo-Json -InputObject @($body) -compress
Source Link

This worked for me, but I had to declare the results in a new variable, or PowerShell just kept breaking down the array into a single object...most frustrating. Thank you Microsoft for not considering the use case of JSON...insert seething sarcasm

$result = ConvertTo-Json -InputObject @($body) -compress