csv to datatable???
i datatables...who doesn't?
well want able put csv datatable or dataset , in powershell (meaning no sql server) can in c#.
i figure create datatable, import csv file , go through csv line line , put in datatable via loop.
is there easier/better way?
cs
i created function called out-datatable transforming powershell output datatable. function available here: http://gallery.technet.microsoft.com/scriptcenter/4208a159-a52e-4b99-83d4-8048468d29dd/
here's example usage:
get-process | export-csv -notypeinformation -path ./process.csv . ./out-datatable.ps1 $dt = import-csv -path .\process.csv | out-datatable
Windows Server > Windows PowerShell
Comments
Post a Comment