Rohith
9
Q:

if data is not available column header should print in output file in powershell

if (-not $DataSet.Tables[0].Rows[0]) {
  ($DataSet.Tables[0].Columns | Select-Object -ExpandProperty ColumnName) -join ',' |
    Set-Content -Path "E:\Users\neerajd\Documents\tethystrader-public-dev-general\src\SQL\Misc\out.csv"
}
0

New to Communities?

Join the community