powershell combine column in CSV
I am trying to automate a CSV file that contains lots of rows of data.
Here is a sample:
==========================
= ID = Last Name =User ID=
= 22 = Smith = 0077 =
= 22 = Smith = 0078 =
= 22 = Smith = 0079 =
= 22 = Jones = 0081 =
and the list goes on.
What I want to do is Combine Column ID with Column Last Name and put it in
a new CSV file using Powershell. I tried the following:
@{n='ID';e={$.ID + "-" + $.Last Name}}
Not much luck with this though.
Any help would be appreciated.
No comments:
Post a Comment