Questions tagged [cfloop]

CFLoop: ColdFusion Loop This is a conditional loop. A conditional loop iterates over a set of instructions as long as a condition is True. To use this type of loop correctly, the instructions must change the condition every time the loop iterates, until the condition is False. Conditional loops are known as WHILE loops, as in, "loop WHILE this condition is true."

<cfloop> is a ColdFusion tag that is used to iterate over data. It supports five different types of loops:

  1. Index Loops
  2. Condition Loops
  3. Looping over a Query
  4. Looping over a List
  5. Looping over a Structure

Read more about the different kinds of loops here

145 questions
0
votes
3 answers

COLDFUSION: How to GROUP by the first column and convert second column into three separate columns

This is a sample of the RAW DATA that I working with from the "employeeRatings" Table before the cfquery output: (showcasing employeeID:1128 for the month of May) employeeID | Possible_Factor | Factor | …
Enchauva
  • 19
  • 5
0
votes
2 answers

Loop through 2 slectboxes submitted values to map to an update query. Coldfusion

I have 2 columns of select boxes. The first (left) is populated by all columns of an uploaded CSV file. The second (right) is all of the columns of a "Clients" table that they can import to. The number of pairs is determined by the number of total…
Steve Ontologic
  • 199
  • 1
  • 11
0
votes
2 answers

ColdFusion10 - query cfloop over an insert query

First post here. I'm using to create a query from Excel and then trying to insert the query results into MySQL table. That's working fine. I also need to take a value from one column and insert its proper ID number into the ID…
RobK
  • 5
  • 3
0
votes
1 answer

Setting radiobutton states dynamically via CFLOOP

I'm using cfloop to dynamically create/fill in three sets of input fields, plus some radio buttons that are used for a rating system. The input fields work as expected. However I'm having trouble with the radio buttons. For some reason (and I'm…
Jason
  • 129
  • 11
0
votes
3 answers

Getting values from CFLOOP

I am trying to pull out values from a CFLOOP and dump them but I seem to be missing something.I need to extract openHours from the first loop and openMinutes from the second and put them in variables that will then run a query for submitting the…
Geo
  • 3,160
  • 6
  • 41
  • 82
0
votes
2 answers

CFLOOP Duplication

I have a drop down list that is generated by two loops. The inner loop generates a series of numbers ie from 0 to 23. The outer loop, is a query loop that selects the correct value from the 23 numbers based on the values stored in my database. My…
Geo
  • 3,160
  • 6
  • 41
  • 82
-1
votes
1 answer

How to return in struct with my cfoutput?

I am trying to output certain key values to show(WHICH I AM GETTING ALREADY). But for some reason it is returning as a struct. Basically, I am converting from query statement into api call. But for some reason I cant get it return from cfoutput to…
-1
votes
1 answer

coldfusion - how to use cfloop file to create an array for a select dropdown

How do I loop through a file and on each cycle of the loop create an array based on that line from the file split at the comma? I have a text file and in the file each line has two numbers separated by a comma. I am trying to loop through the file…
Denoteone
  • 4,043
  • 21
  • 96
  • 150
-3
votes
3 answers

Cf-script convert query result in structure with the unique key?

I have few functions in my system that should be converted from CFML to CFSCRIPT. While working on this project I run to the situation where my structure outputs more result (a lot of empty rows) than it should, even query returns only one row. Here…
espresso_coffee
  • 5,980
  • 11
  • 83
  • 193
-3
votes
3 answers

how to run cfloop on struct results in coldfusion

I am new bie on coldfusion, Please help me to get All ID, Name, Type Using CFLOOP?
Sameek Mishra
  • 9,174
  • 31
  • 92
  • 118
1 2 3
9
10