I am using powershell to get a json object out of my database.
I am getting the json out of my database ok and I can display it to the powershell console. But I am attempting to format that json into a readable form.
I understand the convertFrom-Json cmdlet. But when I run it I am a getting an exception that says:
ConvertFrom-Json : Unterminated string passed in.
This what I have in my powershell script:
$sql = “SELECT CAST(Content as VARCHAR(max)) AS Content FROM %$^%$ WHERE @#$#@ = 2”