Hi,
I have a csv file with 5 columns, the first 3 columns are IPV4 IPs with the 4-6 columns just text. My goal is to Import the CSV, convert to strings, then perform string comparisons using the first 3 columns against other variables.
The issue I'm seeing is an Import-Csv natively creates a PSCustomObject, so I perform the following to create the first column as a string, however this technique doesn't work for the other columns.
$header = "H1", "H2", "H3", "H4", "H5", "H6"
$Data=Import-Csv C:\Data.csv -Header $header | Select -Expand H1
I need the whole row or all columns to be string so I can use in my script for comparisons. How can I do