Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.

  1. #1

    Default order by 2 things?

    Ok, I want my output to look similiar to this:

    ------------------------------------------------------------
    May 16th 2005,

    Animals

    -download animal clip 1
    -download animal clip 2

    automobile

    -download car clip 1

    random

    -download random clip 1

    May 15th 2005,

    Animals

    -download animal clip 1
    -download animal clip 2

    automobile

    -download car clip 1

    random

    -download random clip 1

    -----------------------------------------------------

    I am having a problem looping out query. I loop it, but the date is displayed
    everytime it is looped and i was thinking about putting it in a cfif but i
    wasnt sure what value to check it against. also, they are never organised by
    category, they simply just show each value one by one no matter what
    category...this is currently how it is displaying:

    ex.

    May 16th
    animal
    -download clip 1

    May 16th
    animal
    -download clip2


    if anyone has any idea how to do this i would greatly appreciate it.


    thank you

    davellaman Guest

  2. Similar Questions and Discussions

    1. Tab Order always greyed out, need to redefine order but can't
      I had a check box but then i had to delete it and change it to a text field. now my tab order is all out of whack and I can't seem to set the tab...
    2. Can't I do these things?
      :confused; I am new to Contribute, and I brought to it a set of expectations based on other content management systems I've been exposed to. I'm...
    3. Updating records in order (into an order)
      I'm storing questions for a user-defined quiz. I can store them in the order they are entered without any problem. But... The user needs to have...
    4. Which one of these things is not like the other...
      C'mon, can you tell which one? (Title song from Sesame Street, a PBS Production) http://www.apple.com/ (Apple's website banner displaying the new...
    5. Things to Try >>>
      Well here is a definite design tip, from experience ;-), if you can avoid using MAC for web designing and uploading! DO IT! I'm sorry to all...
  3. #2

    Default Re: order by 2 things?

    I think what you're after is grouped cfoutput, which has to be grouped by the
    query sort order

    Select * from the table order by TheDate

    <cfoutput query="queryname" group="TheDate">
    #TheDate#
    <cfoutput> #Category# #OtherFields#
    </cfoutput>
    </cfoutput>


    OldCFer Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139