Quantcast
Channel: PowerShell
Viewing all articles
Browse latest Browse all 15370

Outputting Sorted Data

$
0
0

Goo'morning Spiceheads,

I'm putting together a script that sifts through an error log. I want this scirpt to find all duplicate logs and then place only one of that specific log with the number of times it occurred. Example "Error BoopBopBeep 5"

I have the sorting part down I just can't seem to get the data to output into a text file, when I output it the file just fills with this:

Microsoft.PowerShell.Commands.GroupInfoNoElement Microsoft.PowerShell.Commands.GroupInfoNoElement Microsoft.PowerShell.Commands.GroupInfoNoElement Microsoft.PowerShell.Commands.GroupInfoNoElement Microsoft.PowerShell.Commands.GroupInfoNoElement

When I check the variable $SortedContent I get what I'm looking for. There just seems to be an issue with my export of that data. Hopefully you guys can help.

Powershell
$StopWatch=[system.diagnostics.stopwatch]::...

Viewing all articles
Browse latest Browse all 15370

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>