Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

More than 1 field to display in CFSELECT??

Status
Not open for further replies.

brown

Technical User
Nov 24, 2000
4
US
Is there any way I can have more than one field name in DISPLAY=".." for CFSELECT? Here is my code, and I'd like the end user to be able to see more than just the tourCity field in the pop-up list. Perhaps the tourCity, tourDate, and tourVenue. Any suggestions?? Thanks.


<CFFORM action=&quot;edit_entry.cfm&quot;>
<CFSELECT name=&quot;stuff&quot; Query=&quot;tourDateList&quot; value=&quot;tourCity&quot; display=&quot;tourCity&quot;>
<OPTION SELECTED>Please select the tour city name</OPTION>
</CFSELECT>
<br><br>
<INPUT type=&quot;Submit&quot;>
</CFFORM>
Ian Hall
Multimedia Designer
 
you want to display tour city, tour date AND tour venue in ONE select field ??
 
Yes, is this possible? (Because there may be more than one concert in the same city, more than one conert on the same date, etc etc...) Ian Hall
Multimedia Designer
 
try :
<FORM action=&quot;edit_entry.cfm&quot;>
<SELECT name=&quot;stuff&quot;>
<OPTION SELECTED>Please select the tour city name, tour Date and tour venue</OPTION>
<cfoutput query=&quot;tourDateList&quot;>
<option value=&quot;#tourCity##tourDate##tourVenue#&quot;>#tourCity#, #tourDate# at #tourVenue# </option>
</cfoutput>
</SELECT>
<br><br>
<INPUT type=&quot;Submit&quot;>
</FORM>
 
Or, you can alias those fields as one in the <cfquery>:

SELECT tourCity+' '+DATANAME(yourserversyntax, tourDate)+' '+tourVebue AS theTour



 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top