Re: [PHP] Re: PHP and MySQL SELECT COUNT (*)

2008-09-18 Thread Vinny Gullotta
Thanks all, I appreciate the follow ups and the help with the code. I'm still relatively new with this stuff, and never had any formal training, it's all just been learn as I go, and I have to learn fast as this project is relatively urgent to get completed. I plan on going through all of my

[PHP] PHP and MySQL SELECT COUNT (*)

2008-09-17 Thread Vinny Gullotta
What I want to do is find the top 10 servers where the column steps = iisreset. The following code works great except that the page is not displaying the servername in the 'Server Name' column of my results (nothing appears, the column is just blank). servername and steps are the important

Re: [PHP] PHP and MySQL SELECT COUNT (*)

2008-09-17 Thread Vinny Gullotta
Dan Joseph [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Wed, Sep 17, 2008 at 2:17 PM, Vinny Gullotta [EMAIL PROTECTED]wrote: What I want to do is find the top 10 servers where the column steps = iisreset. The following code works great except that the page is not displaying

Re: [PHP] PHP and MySQL SELECT COUNT (*)

2008-09-17 Thread Vinny Gullotta
Dan Joseph [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Wed, Sep 17, 2008 at 2:30 PM, Vinny Gullotta [EMAIL PROTECTED]wrote: Dan Joseph [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Wed, Sep 17, 2008 at 2:17 PM, Vinny Gullotta [EMAIL PROTECTED] wrote: What

Re: [PHP] PHP and MySQL SELECT COUNT (*)

2008-09-17 Thread Vinny Gullotta
://www.onshore.com Vinny Gullotta wrote: echo $query; yields SELECT servername, COUNT(steps) as CountSteps FROM monitoring WHERE steps = 'IISRESET' AND timestamp = '2008-09-17 11:40:34' AND timestamp = '2008-08-17' GROUP BY servername ORDER BY COUNT(*) DESC LIMIT 10 -- PHP General Mailing

Re: [PHP] PHP and MySQL SELECT COUNT (*)

2008-09-17 Thread Vinny Gullotta
Dan Joseph [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Wed, Sep 17, 2008 at 2:17 PM, Vinny Gullotta [EMAIL PROTECTED]wrote: What I want to do is find the top 10 servers where the column steps = iisreset. The following code works great except that the page is not displaying

Re: [PHP] PHP and MySQL SELECT COUNT (*)

2008-09-17 Thread Vinny Gullotta
Internal Developer http://www.onshore.com Vinny Gullotta wrote: Still no luck displaying the stupid servername. Any other things I can try? Micah Gersten [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] You'll want to change your Order By statement to 'ORDER BY CountSteps DESC'. Thank you

Re: [PHP] PHP and MySQL SELECT COUNT (*)

2008-09-17 Thread Vinny Gullotta
[EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Wed, Sep 17, 2008 at 4:21 PM, Vinny Gullotta [EMAIL PROTECTED]wrote: var_dump($i); looks messy, but I can see the server names in there and they are the correct names. Micah Gersten [EMAIL PROTECTED] wrote in message news:[EMAIL

Re: [PHP] PHP and MySQL SELECT COUNT (*)

2008-09-17 Thread Vinny Gullotta
://www.onshore.com Vinny Gullotta wrote: var_dump($i); looks messy, but I can see the server names in there and they are the correct names. Micah Gersten [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Do var_dump($i) in the loop to see if you're getting the data you want. Thank you

Re: [PHP] PHP and MySQL SELECT COUNT (*)

2008-09-17 Thread Vinny Gullotta
That was it!!! Thank you all so much for your help!!! =D Dan Joseph [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Wed, Sep 17, 2008 at 4:30 PM, Vinny Gullotta [EMAIL PROTECTED]wrote: If by key you mean the column in the database, it's called: servername Micah Gersten [EMAIL

[PHP] Incrementing variables based on database data

2008-08-12 Thread Vinny Gullotta
below is the output I'm seeing along with my code. There are 11425 items in the database, many of each of these possible values for $i[4], however you'll see from my Output that the $iiscount variable is the only one being incremented and it is getting incremented for every row in the table.

[PHP] Re: Incrementing variables based on database data

2008-08-12 Thread Vinny Gullotta
Nevermind, I figured it out. I needed to make the if statements use == instead of = like this: if ($i[4] == IISRESET) { $iiscount = $iiscount + 1; } etc. =) Vinny Gullotta [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] below is the output I'm seeing along with my code

Re: [PHP] Re: Incrementing variables based on database data

2008-08-12 Thread Vinny Gullotta
not let the DB do this for you? You can group by whatever column that is and select count(*), column_your_looking_for. Thank you, Micah Gersten onShore Networks Internal Developer http://www.onshore.com Vinny Gullotta wrote: Nevermind, I figured it out. I needed to make the if statements use

Re: [PHP] PHP querying mysql db for data limited to the last month

2008-08-05 Thread Vinny Gullotta
://www.onshore.com Vinny Gullotta wrote: So I have this code I'm working with (pasted below) that queries a mysql db table called timetracking. The goal of the page is to search the db for all data based on a certain engineer, sorted by product and it takes pre-defined values based on actions

[PHP] PHP querying mysql db for data limited to the last month

2008-08-04 Thread Vinny Gullotta
in the SELECT statement, some while statements and if statements, and all I do is keep breaking it. If anyone has any ideas, it would be exceptionally helpful. Thanks in advance, Vinny ?php $total = 0; $today = date('Y-m-d h:i:s'); $monthago = date(Y-m-d h:i:s, mktime(date(h), date(i), date(s), date(m)-1

[PHP] Referring to Parent Folders

2004-02-13 Thread Vinny
assume it is not a problem with Apache. So my question is, is this simply a PHP config problem? PHP 4.3.4 Apache 1.3.something Thanks! Vinny -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] important linuxtoday article: Will Open Source Lose the Battle for the web?

2001-08-15 Thread Vinny
hmm just read the controversial linuxtoday article http://linuxtoday.com/news_story.php3?ltsn=2001-08-13-009-20-OP an excerpt: but when will PHP grow to become something more than a web scripting language? Where is the PHP enterprise component architecture? What about clustering and failover?