shew (10/11/2012)
Any ideas on how to return the results of a SQL query as a PowerShell object?
I'm no Powershell Ninja by any means so I don't know the Powershell answer to this but I'm sure this is one. In the meantime, couldn't you just BCP the results out to a file using SQLCMD and open the file in Powershell?
By the same token, I'm not sure that PowerShell is the answer here. Why not create a spreadsheet that looks at external data through a pass-through view and plot from that?
--Jeff Moden
Change is inevitable... Change for the better is not.