title: export csv from json file using powershell
body: <p>I do have a json file like this:
      { "skip" : 0,
        "take" : 100,
        "rows" : [
        {
          "WG": "1013",
          "Werkgever": "1013",
          "Cao": "0000"
        }
      ]}</p>
  
  <p>Now I do need to convert this to csv file like this using powerhsell</p>
  
  <pre><code>"WG","Werkgever","Cao"
  "1013","1013","0000"
  </code></pre>
  
  <p>The script is:</p>
  
  <h1>Json conversion to CSV</h1>
  
  <pre><code>Get-Content -Raw $file |
    ConvertFrom-Json |
    select @{n='WG';e={$_.WG | select -Expand WG}},
           @{n='Werkgever';e={$_.Werkgever | select -Expand Werkgever}},
           @{n='Cao';e={$_.Cao| select -Expand Cao}}|
  Export-Csv $FileName1 -NoType
  </code></pre>
  
  <p>Only I do miss the value....
  It comes out like:</p>
  
  <pre><code>"WG","Werkgever","Cao"
  "","",""
  </code></pre>
  
  <p>What do I do wrong?</p>