You are here: Re: number of entries in a date column « PHP SQL « IT news, forums, messages
Re: number of entries in a date column

Posted by Rich on 12/06/05 20:47

In article <1133800584.935958.48240@f14g2000cwb.googlegroups.com>, bigsamurai
says...
>
>i am trying to determine the number of entrys by this person between
>these dates.
>

As Bob mentioned you need to use the "group by" with the "count" to get a
summary for each person. The "<labels>" are generic names used below that would
have to be replaced with your information. Borrowing from Bob, maybe something
like...

Select count(*) as entries, <officer_name>
FROM <table_name>
GROUP BY ood_date, <officer_name>
WHERE ood_date >= '<low_date>' AND ood_date <= '<high_date>';

Maybe the problem is related to trying to include the ood_date in the select. If
you just need the count without the specific date information you might be able
to simplify your query.


Rich
--
Newsguy -- http://newsguy.com

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация