Invoke-sqlcmd output without “quotes” and headers
问题 Output example: #TYPE System.Data.DataRow <--- "PersonalNr" <--- "00001005" "00001008" "00001009" "00001013" "00001019" "00001024" Requirements: I want a output without the 2 first lines and without the quote symbols, how can i do that? For the headers I tried the options -h -1 but the output is still the same. Is it even possible with Sqlcmd ? Current Code: Invoke-Sqlcmd -ServerInstance SERVER -h -1 -Query $QueryFmt | Export-CSV $AttachmentPath 回答1: This code should work: Invoke-Sqlcmd