Skip to main content
Inspiring
April 29, 2008
Answered

Date won't show up

  • April 29, 2008
  • 2 replies
  • 439 views
I have no idea why the date field "#LSDateFormat(qRegisteredStudentsMonth.eventDate,'M/DD/YY')#" --line 29 won't show up in the html. I KNOW that the data is there in the database.

Any help would be appreciated!!
    This topic has been closed for replies.
    Correct answer Watch4him
    Problem solved. gave the database the once over and found someone had added a eventDate field to another table. This field was completely empty. Wonder why CF didn't bring up duplicate field name errors.....

    2 replies

    Inspiring
    April 29, 2008
    Spirit_Filled wrote:
    > WHERE tbl_eventRegistration.eventDate LIKE '#URL.month#/%/#URL.year#'

    unless eventDate is a char/varchar data type, i don't believe this will produce
    any results.
    Inspiring
    April 29, 2008
    What happens when you cfdump the query? For what it's worth, this line
    where tbl_eventRegistration.eventDate LIKE '#URL.month etc
    suggests that you are storing dates as text which makes your data much less useful than if you stored them as dates.
    Watch4himAuthor
    Inspiring
    April 29, 2008
    The dump comes back as [empty string] The data is actually being stored as date/time and not as text. I'm fairly new to Coldfusion (started about two weeks ago) and just needed a quick and dirty way to pull all records for that month.(hence the LIKE wildcard statement) Seemed to work, until the date didn't show up.
    Watch4himAuthorCorrect answer
    Inspiring
    April 29, 2008
    Problem solved. gave the database the once over and found someone had added a eventDate field to another table. This field was completely empty. Wonder why CF didn't bring up duplicate field name errors.....