0

I am new to the PowerShell world, and my need is very simple. I found this utility https://github.com/dfinke/ImportExcel that meets my need but I could not find a suitable exampe But I am struggling to find an answer.Any help is appreciated My data model is as follows

$leftCsv = @"
Column1,Column2,Id
1,2,10
11,22,100
"@ | ConvertFrom-Csv

$rightCsv = @"
Column3,Column4,Id
3,4,10
33,44,100
"@ | ConvertFrom-Csv

and the expected output is

Id,Column1,Column2,Column3,Column4
10,1,2,3,4
100,11,22,33,44

Thanks Sanchu

4
  • Is this not essentially the exact same as stackoverflow.com/questions/69213006/… that I answered earlier today? Commented Sep 16, 2021 at 19:23
  • I think your answer is using plain PowerShell functions whereas my question is about resolving using this utility. github.com/dfinke/ImportExcel. Please forgive me if I am wrong Commented Sep 16, 2021 at 20:12
  • Either way you end up with an array of objects. The only difference is really loading and exporting the objects, now how you manipulate them. Commented Sep 16, 2021 at 20:18
  • In my case the columns in both files are dynamic except a common column. I am from Linux world and this really looks Chinese to me Commented Sep 16, 2021 at 20:26

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.