I was very skeptical as always. now you are comparing strings instead of working with objects, so there some reasone in jrv recommendations ;), if you will provide some sample data would be easyer help you with solution, The opinion expressed by me is not an official position of Microsoft. Short story about swapping bodies as a job; the person who hires the main character misuses his body. Your daily dose of tech news, in brief. See you tomorrow. Something you know will exist to identify items (users) in each file that must exist in both files. Site design / logo 2023 Stack Exchange Inc; user contributions licensed under CC BY-SA. You completely misunderstand the issue. Comparing 2 CSV files in powershell exporting difference to another file, How a top-ranked engineering school reimagined CS curriculum (Ep. You will absolutely need it in the future. Content Discovery initiative April 13 update: Related questions using a Review our technical responses for the 2023 Developer Survey. Let me give this a shot. Unfortunately, I'm doing the best I can with my limited skill set and available time. The main issue is that you think using vague VB5 collage examples and have no experience in progr4amming. To do this, I highlight the Compare-Object statement and press F-8 to execute only that portion of the code. Hi Rich, thanks for your help. Although this works, it can be a bit slow, and on more complex files, I would think it would also be a bit unreliable. technically do the rest in VBS, but it will be longer and ugly and obviously not 40yr professional level work. How can I control PNP and NPN transistors together from one pin? What is Wario dropping at the end of Super Mario Land 2 and why? Michael Holste What's the best way to determine the location of the current PowerShell script? On lines 6 and 7 you look to be simply reading the contents of the reference and difference files instead of using Import-CSV. Canadian of Polish descent travel to Poland with Canadian passport. What is the difference between Powershell -command and -argumentlist? The following free book is0one of the best for quickly learning PowerShell correctly. Interpreting non-statistically significant results: Do we have "no evidence" or "insufficient evidence" to reject the null? Let's start with this: Windows-PowerShell-4. Site design / logo 2023 Stack Exchange Inc; user contributions licensed under CC BY-SA. $UserList = Import-Csv -Path "$($path)\Userlisr.csv" Assuming the two csv files are identical in (number/name/type/order) of columns.