Skip to main content
Inspiring
May 23, 2008
Question

formatting date inside a returned recordset

  • May 23, 2008
  • 2 replies
  • 215 views
Hi,

I have a recordset that has a date as part of what's shown. I've tried
various ways to format the dynamic text (I'd like something like: May 23,
2008), but I can't get it to work. So, if I had as part of the output
table:

<cfoutput query="rsMp3Search">
<tr bgcolor="###iif(currentrow MOD 2,DE('FFFF99'),DE('CCFFFF'))#">
<td width="11%" height="45"><div
align="center">#rsMp3Search.SpeakerLName#</div></td>
<td width="10%"><div
align="center">#rsMp3Search.speaker_FName#</div></td>
<!--- <td width="17%"><div
align="center"><cfoutput>#DateFormat(rsMp3Search.Speak_date, 'mmmm dd,
yyyy')#</cfoutput></div></td>--->
<td width="17%"><div
align="center">#rsMp3Search.Speak_date#</div></td>
<td><div align="center">#rsMp3Search.Title#</div></td>
<td bgcolor="###iif(currentrow MOD 2,DE('FFFF99'),DE('CCFFFF'))#">
<div align="center"><a
href="#rsMp3Search.mp3_file#">#rsMp3Search.mp3_file#</a></div></td>
<td bgcolor="###iif(currentrow MOD
2,DE('FFFF99'),DE('CCFFFF'))#">#rsMp3Search.Speak_type#</td>
<!---<td width="8%">#rsSearchMembers.Birth_Date#</td>--->
</tr>
</cfoutput>

How would I make the <td> that's commented out work the way I'd like?

Thanks very much for your advice.













9i'd like something like


This topic has been closed for replies.

2 replies

Inspiring
May 23, 2008
Perfect! Thank you. I am dumb.
"Jim Fulmer" <jfulme1@comcast.net> wrote in message
news:g16nto$58j$1@forums.macromedia.com...
> Hi,
>
> I have a recordset that has a date as part of what's shown. I've tried
> various ways to format the dynamic text (I'd like something like: May 23,
> 2008), but I can't get it to work. So, if I had as part of the output
> table:
>
> <cfoutput query="rsMp3Search">
> <tr bgcolor="###iif(currentrow MOD 2,DE('FFFF99'),DE('CCFFFF'))#">
> <td width="11%" height="45"><div
> align="center">#rsMp3Search.SpeakerLName#</div></td>
> <td width="10%"><div
> align="center">#rsMp3Search.speaker_FName#</div></td>
> <!--- <td width="17%"><div
> align="center"><cfoutput>#DateFormat(rsMp3Search.Speak_date, 'mmmm dd,
> yyyy')#</cfoutput></div></td>--->
> <td width="17%"><div
> align="center">#rsMp3Search.Speak_date#</div></td>
> <td><div align="center">#rsMp3Search.Title#</div></td>
> <td bgcolor="###iif(currentrow MOD 2,DE('FFFF99'),DE('CCFFFF'))#">
> <div align="center"><a
> href="#rsMp3Search.mp3_file#">#rsMp3Search.mp3_file#</a></div></td>
> <td bgcolor="###iif(currentrow MOD
> 2,DE('FFFF99'),DE('CCFFFF'))#">#rsMp3Search.Speak_type#</td>
> <!---<td width="8%">#rsSearchMembers.Birth_Date#</td>--->
> </tr>
> </cfoutput>
>
> How would I make the <td> that's commented out work the way I'd like?
>
> Thanks very much for your advice.
>
>
>
>
>
>
>
>
>
>
>
>
>
> 9i'd like something like
>


Inspiring
May 23, 2008
Jim Fulmer wrote:

> Thanks very much for your advice.
>

Assuming that 'Birth_Date' is a date type field like it should be it;
would simply be #dateFormat(rsSearchMembers.Birth_Date,"mmm dd, yyyy")#.

If 'Birth_Date' is not a date type field, but rather a string or number
type then you have a much more difficult display problem.