ericb1 Posted March 4, 2009 Report Share Posted March 4, 2009 Sorry for the newbie question, I'm trying to get up to speed with Power Gadgets. I've got a thermometer gague, with the data coming from my sql server. The documentation says to return only a single variable, but my sql returns 2 variables: an actual value and a goal value. So I would like to have my "goal" value as the maximum value and my "actual" value as the indicator. So that when it refreshes, the actual value will keep increasing towards the top of the thermometer, which is the goal. Any help is greatly appreciated, thanks! Quote Link to comment Share on other sites More sharing options...
marco.shaw Posted March 5, 2009 Report Share Posted March 5, 2009 You may not be able to provide the SQL script, but can you show how the values are retunrned? Just simply copy and paste how the values are outputted, and possibly add this to the end of your PowerShell command or script "|get-member". Using get-member allows me to see what kind of object is outputted. It is possibly a string, but could also be some kind of SMO object (Sql server Management Object). Marco Quote Link to comment Share on other sites More sharing options...
ericb1 Posted March 5, 2009 Author Report Share Posted March 5, 2009 thanks so much for the help. My resulting sql looks like this: Total 94561 7855 One row with 2 or 3 columns. I can change it around though if needed. So I'm trying to get the top of the gague to be 94,561, and the filler part to only read 7,855. The goal of 94,561 is a monthly goal and onlu changes at the beginning of every month. The "actual" number of 7,855 increases steadily throughout the month as we try to reach our goal. My script looks like this: SELECT 'Total',(SELECT SUM(totalprocessed) FROM vw_total_numbers_0 WHERE RIGHT(trust,4) = 'goal') AS 'Total Goal',(SELECT SUM(totalprocessed) FROM vw_total_numbers_0 WHERE RIGHT(trust,4) <> 'goal') AS 'Actual' Thanks again! Quote Link to comment Share on other sites More sharing options...
marco.shaw Posted March 5, 2009 Report Share Posted March 5, 2009 OK, so that is likely a simple string returned. Hopefully you can give me a day. I had to change computers and no longer have PowerGadgets installed. Quote Link to comment Share on other sites More sharing options...
marco.shaw Posted March 20, 2009 Report Share Posted March 20, 2009 I did look at this quickly. Unless I'm missing something, I can't see a way to add 2 values. I do see that you can make the max value something specific, but I can't see how to make 2 "pointers"... I'll look at this some more next week. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.