473,466 Members | 1,329 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

REQ: Simple Query

Dan
Hi all! I am creating a Disney "Today in History" database, and so
far have about 300 entries in it. Well, my Access database is great,
and my Frontpage form is great, but I want to include a short "On this
date in Disney history....<event>" on my main web page. Basically,
if someone goes to my web page, they'll automatically see this if
there is an event that occurred on this day.

So, my problem is... how do I create an SQL database that shows ONLY
the events from today? Like, "On September 4, 1931, Walt
Disney...yadda yadda yadda." My SQL query must be wrong because
nothing is getting displayed for events on days that I KNOW there are
events.

Here is my query...

SELECT * FROM Results WHERE (Month = '::Month::' AND Day =
'::Day::')

This doesn't display any events on the day I choose (and I've changed
the date a few times on my computer to match days that have data in
them). Can someone help me to make a query that might work to display
the results of the Month and Day only? (They're both separate fields
in my access database).

If you want to check it out, go to http://www.bbdisney.com/tih.asp

Thanks!
Dan

da*******@NOSPAMshaw.ca

Nov 12 '05 #1
2 2605
Basically without seeing your table that you are querying, the easiest
solution I have for you is to create a query using the query wizard,
then open it and put in the criteria in the query. If you get results,
then open the query in SQL format and you will see the SQL statement
that you need.

Hope this helps.

John
Dan <da***@shaw.ca> wrote in message news:<mj********************************@4ax.com>. ..
Hi all! I am creating a Disney "Today in History" database, and so
far have about 300 entries in it. Well, my Access database is great,
and my Frontpage form is great, but I want to include a short "On this
date in Disney history....<event>" on my main web page. Basically,
if someone goes to my web page, they'll automatically see this if
there is an event that occurred on this day.

So, my problem is... how do I create an SQL database that shows ONLY
the events from today? Like, "On September 4, 1931, Walt
Disney...yadda yadda yadda." My SQL query must be wrong because
nothing is getting displayed for events on days that I KNOW there are
events.

Here is my query...

SELECT * FROM Results WHERE (Month = '::Month::' AND Day =
'::Day::')

This doesn't display any events on the day I choose (and I've changed
the date a few times on my computer to match days that have data in
them). Can someone help me to make a query that might work to display
the results of the Month and Day only? (They're both separate fields
in my access database).

If you want to check it out, go to http://www.bbdisney.com/tih.asp

Thanks!
Dan

da*******@NOSPAMshaw.ca

Nov 12 '05 #2
Hey Dan,
Do you have a table called Results in your database? You can create a
stored procedure or query whih accepts parameters . You can the feed
the query with the reqd params from your ASP page orVisual Basic form.
You SQL seems to be right, if ::Dy:: and ::Month:: are the variables
you are trying to accept!
Hope this helps,
Yegnaram Iyer
www.geocities.com/yegnaramiyer
Dan <da***@shaw.ca> wrote in message news:<mj********************************@4ax.com>. ..
Hi all! I am creating a Disney "Today in History" database, and so
far have about 300 entries in it. Well, my Access database is great,
and my Frontpage form is great, but I want to include a short "On this
date in Disney history....<event>" on my main web page. Basically,
if someone goes to my web page, they'll automatically see this if
there is an event that occurred on this day.

So, my problem is... how do I create an SQL database that shows ONLY
the events from today? Like, "On September 4, 1931, Walt
Disney...yadda yadda yadda." My SQL query must be wrong because
nothing is getting displayed for events on days that I KNOW there are
events.

Here is my query...

SELECT * FROM Results WHERE (Month = '::Month::' AND Day =
'::Day::')

This doesn't display any events on the day I choose (and I've changed
the date a few times on my computer to match days that have data in
them). Can someone help me to make a query that might work to display
the results of the Month and Day only? (They're both separate fields
in my access database).

If you want to check it out, go to http://www.bbdisney.com/tih.asp

Thanks!
Dan

da*******@NOSPAMshaw.ca

Nov 12 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Dariusz | last post by:
I am a beginner in PHP and MySQL, and am working through a book and various online tutorials on PHP and MySQL and now stuck - installed everything on "localhost" and it all works fine. My question...
4
by: Gleep | last post by:
Hey Guys, I've got a table called Outcomes. With 3 columns and 15 rows 1st col 2nd col 3rdcol outcome date price There are 15 rows...
9
by: Gleep | last post by:
sorry i didn't explain it correctly before my table is like this example fields: ID name username outcome date1 date2 date3 (etc..) - date15 price1 price2 price3 (etc..) I know that...
2
by: John F Dutcher | last post by:
Can anyone comment on why the code shown in the Python error is in some way incorrect...or is there a problem with Python on my hoster's site ?? The highlites don't seem to show here...but line...
0
by: Jonas Gorauskas | last post by:
I am having this one problem on an app I am writing where it shows the following error on some error trapping that I did: Query failed: Error Number: 1064 Description: You have an error in...
5
by: Sue | last post by:
After finishing up my first quarter JavaScript on 12/12/03, I decided to improve character checking on my project. In my project I only had to do very basic validation. Therefore, I only had one...
18
by: Gleep | last post by:
I've searched google intensely on this topic and it seems noone really knows how to approch this. The goal I don't want clients to give out their usernames and passwords to friends, since the site...
3
by: dad | last post by:
I am building a database to track the maintenance records on a fleet of cars. I need to run a report on that will display data based on whether a box is checked or not (i.e. all cars that have the...
1
by: sitanshuwesley | last post by:
i hve written the followin query in VBS isql = "insert into googleQuery(filename,CompanyID,QueryText) values (" & fname & "," & rs.Fields(0) & ",""" & rs.Fields(3) & """" & ")" while...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.