Troubleshooting

1. see if simple queries (one table) work -- they do
2. take out the WHERE clause to make certain the join works -- it does

The error is with the date as the WHERE clause works with other fields

Can there be a date v date/time issue?

If so how to determine it?

I'm inputting dates in the format m/d/yyy
and passing the parameter in the same way

The output of  #createodbcdatetime(eventDay)#  is {ts '2003-10-15 00:00:00'}
The output of #classDate# is 2003-10-15 00:00:00.0

The SQL once again is:

SELECT classes.*, classDates.*
FROM classes INNER JOIN classDates ON classes.classID = ""> WHERE classDate=#createodbcdatetime(eventDay)#

gil

-----Original Message-----
From: Jochem van Dieten [mailto:[EMAIL PROTECTED]
Sent: Thursday, October 16, 2003 3:27 PM
To: CF-Talk
Subject: Re: trouble shooting advice WAS: SQL join not working

  mayo wrote:
  > For the following SQL there is no error, I just don't get any records
...

  Verify there are actual records present. Easiest way is to change
  your inner join to a full outer join and see what happens.

  > NOT TRUE, and maybe significant -- I only get the first record in the
  > classes table on days when that entry exists. !?! (I'm doing an
<cfoutput
  > query=queryname> so I'm really confused.)

  Use cfdump.

  >  SELECT classes.*, classDates.*
  >  FROM classes INNER JOIN classDates ON classes.classID =""> classDates.classID
  >  WHERE classDate=#createodbcdatetime(eventDay)#

  Use cfqueryparam.

  Jochem


[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to