EasyCFM.COM ColdFusion Forums / Coding Help! / some help with queries

   Reply to Discussion | New Discussion << previous || next >> 
Posted By Discussion Topic: some help with queries

book mark this topic Printer-friendly Version  send this discussion to a friend  new posts last

125pr
04-15-2006 @ 3:35 AM
Reply
Edit
Profile
Send P.M.
My Gravatar!
Powered by Gravatar
Junior Member
Posts: 68
Joined: Oct 2005

Hi I have my Own Forums But i have some Problem Facing it, So as I would like to Discuss with you, I have my one page which shows the topics_active within the day, my database is MYSQL version 5 and i administer it with phpmyadmin

well the code which causing me the problem is:

<cfloop query="GetTopics">
<cfif #DateCompare(Post_Update,  DateFormat(now(), 'MM/DD/YYYY'))# is "0">
<cfset topicslist = listappend(topicslist, post_id)>
</cfif>

I know this is some kinda programming error but i am unable to rectify it, if yoiu provide me with some help it will be greatly appreciated.

also it posts the error as like:

The system has attempted to use an undefined value, which usually indicates a programming error, either in your code or some system code.
Null Pointers are another name for undefined values.


well I tried the mysql posts table and retified the date time table structure parameres to match with the now() function but still the problem persistes, How can I solve that, if you could plz let me know



Gurpreet Singh Randhawa
www.randhawaz.com

falconseye
04-18-2006 @ 1:09 PM
Reply
Edit
Profile
Send P.M.
My Gravatar!
Powered by Gravatar
Senior Member
Posts: 1033
Joined: Mar 2004

<cfoutput query="GetTopics">
<cfif DateCompare(#Post_Update#,  DateFormat(now(), 'MM/DD/YYYY')) EQ 0>
<cfset topicslist = listappend(topicslist, #post_id#)>
</cfif>
</cfoutput>

hope it helps...

125pr
04-22-2006 @ 8:48 AM
Reply
Edit
Profile
Send P.M.
My Gravatar!
Powered by Gravatar
Junior Member
Posts: 68
Joined: Oct 2005

same error

Gurpreet Singh Randhawa
www.randhawaz.com

Ron
04-22-2006 @ 4:18 PM
Reply
Edit
Profile
Send P.M.
My Gravatar!
Powered by Gravatar
Senior Member
Posts: 244
Joined: Oct 2004

cfparam 'Post_Update' with a default value

<cfparam name='Post_Update' default="#now()#" type="date">

This message was edited by Ron on 4-22-06 @ 4:19 PM


Website Designed and Developed by Pablo Varando.