| Contents > CFML Reference > ColdFusion Functions > ValueList |
|
|
|
|
||
Inserts a delimiter between each value in an executed query. ColdFusion does not evaluate the arguments.
A delimited list of the values of each record returned from an executed query.
Other functions, Query functions
ValueList(query.column [, delimiter ])
Parameter |
Description |
|---|---|
query.column |
Name of an executed query and column. Separate query name and column name with a period. |
delimiter |
A delimiter character to separate column data items. Default: comma (,). |
<h3>ValueList Example</h3> <!--- use the contents of a query to create another dynamically ---> <cfquery name = "GetDepartments" datasource = "cfsnippets"> SELECT Dept_ID FROM Departments WHERE Dept_ID IN (`BIOL') </cfquery> <cfquery name = "GetCourseList" datasource = "cfsnippets"> SELECT * FROM CourseList WHERE Dept_ID IN (`#ValueList(GetDepartments.Dept_ID)#') </cfquery> <cfoutput QUERY = "GetCourseList" > <pre>#Course_ID# #Dept_ID# #CorNumber# #CorName#</pre> </cfoutput>
|
|
||
| Contents > CFML Reference > ColdFusion Functions > ValueList |
|
|
ColdFusion 8 | ColdFusion MX 7 | ColdFusion MX 6.1 | ColdFusion MX | Forums | Developer Center | Bug Reporting
Version 6.1
Comments are no longer accepted for ColdFusion MX 6.1. ColdFusion 8 is the current version.
RSS feed | Send me an e-mail when comments are added to this page | Comment Report
Current page: http://livedocs.adobe.com/coldfusion/6.1/htmldocs/funca117.htm
Comments
No screen name said on Mar 18, 2004 at 2:58 AM : tzimmerman said on Apr 27, 2004 at 3:12 PM : NAGUIT_ALA said on Jan 28, 2005 at 3:39 PM : CFSMITA said on Apr 15, 2005 at 11:35 AM :