|
 |
asp_web_howto thread: Have a Counter of records by Day
Message #1 by "Omar Esquivel" <omare@u...> on Mon, 22 Jul 2002 17:50:29
|
|
Hi,
I need to have a counter of records based on how many records where
entered by day. As for example, if there was only one record entered that
day then the reference number would be 1. If there were 20 records for
that particular date then the number would be 20. You get the picture.
I enter the records by a submit form, then right after the submit I
display all the fields that were just entered, including the updated
counter for the day, which has to count for all previous records for that
day if there were any, plus this last one.
Any help with this would be greatly appreciated
Thank you
Omare
Message #2 by "Paulo Fernandes" <paulofernandes@c...> on Mon, 22 Jul 2002 19:00:54 +0100
|
|
Hi,
I had to do this same thing on a project of mine.
The solution I found was to create a query in access that would count
the records of the table where I stored the values (in your case, a
query that groups and counts the records on a per day basis). This
improved the response time, when compared to executing the same SQL
command thru ASP.
Then, on the asp page all I had to do was to open the query and search
for the day (in your case the day = current date) and display the count
of field with something like:
strSQL="SELECT COUNT FROM QRY_BY_DAY_RECORDS WHERE DATE LIKE '" & DATE()
& "'"
This worked for me... I hope it'll work for you too.
Cheers.
PauloF
-----Original Message-----
From: Omar Esquivel [mailto:omare@u...]
Sent: segunda-feira, 22 de Julho de 2002 17:50
To: ASP Web HowTo
Subject: [asp_web_howto] Have a Counter of records by Day
Hi,
I need to have a counter of records based on how many records where
entered by day. As for example, if there was only one record entered
that
day then the reference number would be 1. If there were 20 records for
that particular date then the number would be 20. You get the picture.
I enter the records by a submit form, then right after the submit I
display all the fields that were just entered, including the updated
counter for the day, which has to count for all previous records for
that
day if there were any, plus this last one.
Any help with this would be greatly appreciated
Thank you
Omare
---
Improve your web design skills with these new books from Glasshaus.
Usable Web Menus
http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
r-20
Constructing Accessible Web Sites
http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
r-20
Practical JavaScript for the Usable Web
http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
r-20
|
|
 |