Solved

is this funky cfoutput query trick possible?

Posted on 2003-12-03
3
238 Views
Last Modified: 2013-12-24
this query is generating dates:

January 15 8:30AM
January 15 12:30PM
January 17 8:30AM
January 17 1:30PM
January 20 8:30AM
January 20 11:30AM
January 20 1:30PM

any way to put a space between the dates w/o reworking the entire thing too drastically:

January 15 8:30AM
January 15 12:30PM

January 17 8:30AM
January 17 1:30PM

January 20 8:30AM
January 20 11:30AM
January 20 1:30PM


<cfquery name="rsTimes" datasource=#MM_connCalArts_DSN# username=#MM_connCalArts_USERNAME# password=#MM_connCalArts_PASSWORD#>
SELECT count(*) as slotsremain,  timeslots_theater.timeslots, mix_theater.cities_id, cities_theater.cities,
mix_theater.timeslots_id, mix_theater.mix_id, timeslots_theater.id, exact_location FROM timeslots_theater,
mix_theater, cities_theater WHERE timeslots_theater.id = mix_theater.timeslots_id
AND cities_theater.id = mix_theater.cities_id AND cities_id = '#rsTimes__MMColParam#'
group by timeslots
order by timeslots asc
</cfquery>

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

<cfoutput query="rsTimes" group="timeslots">
    <li><A HREF="application.cfm?#Trim(MM_keepURL & Iif(MM_keepURL NEQ '',DE('&'),DE('')) & 'mix_id=' & rsTimes.mix_id)#" class="craig">#dateformat(rsTimes.timeslots, 'mmmm d, yyyy')#&nbsp; #timeformat(rsTimes.timeslots, 'h:MM tt')#</A> <br>
  </cfoutput>
0
Comment
Question by:phillystyle123
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 6

Expert Comment

by:PE_CF_DEV
ID: 9869768
<cfoutput query="rsTimes" group="timeslots">
    <li><A HREF="application.cfm?#Trim(MM_keepURL & Iif(MM_keepURL NEQ '',DE('&'),DE('')) & 'mix_id=' & rsTimes.mix_id)#" class="craig">#dateformat(rsTimes.timeslots, 'mmmm d, yyyy')#&nbsp;
        <cfoutput>
              #timeformat(rsTimes.timeslots, 'h:MM tt')#</A> <br>
         </cfoutput>
<br>
  </cfoutput>

just asking but why would you have a link to application.cfm? Seems sort of useless since application.cfm gets called on each request anyway....
0
 
LVL 6

Accepted Solution

by:
PE_CF_DEV earned 100 total points
ID: 9869841
wait I messed up I read the output wrong....
<cfset pastdate=dayofyear(rsTimes.timeslots[1])>
<cfoutput query="rsTimes">
<cfif pastdate NEQ dayofyear(rsTimes.timeslots)>
   <br>
</cfif>
<cfset pastdate=dayofyear(rsTimes.timeslots)>
    <li><A HREF="##">#dateformat(rsTimes.timeslots, 'mmmm d, yyyy')#&nbsp; #timeformat(rsTimes.timeslots, 'h:MM tt')#</A> <br>
  </cfoutput>

It also helps If I get the function right....dayofyear()
0
 

Author Comment

by:phillystyle123
ID: 9869994
awesome - works perfectly
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A web service (http://en.wikipedia.org/wiki/Web_service) is a software related technology that facilitates machine-to-machine interaction over a network. This article helps beginners in creating and consuming a web service using the ColdFusion Ma…
When it comes to security, close monitoring is a must. According to WhiteHat Security annual report, a substantial number of all web applications are vulnerable always. Monitis offers a new product - fully-featured Website security monitoring and pr…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question