*another embarressed look*
I..figured it out. Left worked fine..I just thought that might be quicker
than Like A%..
But..I had a ; somewhere in the SQL that was preventing it from reading any
further, hence throwing an error.
*shakes head*
Darn...
But thanks guys..oh and if anyone wants to know, here is the code I wrote.
This will give you letters from A to Z along the top that would display the
appropriate categories.
This is very simple code, however I thought it might just help someone.
-Gel
<CFIF IsDefined("letter")>
<CFQUERY Name="categorylist" datasource="xxxxx">
SELECT DISTINCT xxxx.Classification
FROM xxxx
Where Left(xxxx.Classification,1) = '#Letter#';
</CFQUERY>
<CFELSE>
<CFQUERY Name="categorylist" datasource="xxxxx">
SELECT DISTINCT xxxx.Classification
FROM xxxxx;
</CFQUERY>
</CFIF>
<html>
<head>
<title>Show Category List</title>
</head>
<body>
<Form ACTION="yp_results.cfm" METHOD="POST">
<p>Enter the keywords you wish to search for here.<br>
You may search for Names (First Name,Last Name), Company Names, Zip
Codes,<br>
Categories,Address Or State.
<Input type="hidden" name="StartRow" Value="1">
<br>
Keywords:
<Input type="text" name="Criteria" size = 30>
</p>
<p>
<input type="submit" name="Submit" value="Search">
<input type="reset" name="Submit2" value="Reset">
</p>
</FORM>
<P align="center">
[<a href="categorylist.cfm?letter=A"> A</a>]
[<a href="categorylist.cfm?letter=B"> B</a>]
[<a href="categorylist.cfm?letter=C"> C</a>]
[<a href="categorylist.cfm?letter=D"> D</a>]
[<a href="categorylist.cfm?letter=E"> E</a>]
[<a href="categorylist.cfm?letter=F"> F</a>]
[<a href="categorylist.cfm?letter=G"> G</a>]
[<a href="categorylist.cfm?letter=H"> H</a>]
[<a href="categorylist.cfm?letter=I"> I</a>]
[<a href="categorylist.cfm?letter=J"> J</a>]
[<a href="categorylist.cfm?letter=K"> K</a>]
[<a href="categorylist.cfm?letter=L"> L</a>]
[<a href="categorylist.cfm?letter=M"> M </a>]
[<a href="categorylist.cfm?letter=N"> N</a>]
[<a href="categorylist.cfm?letter=O"> O</a>]
[<a href="categorylist.cfm?letter=P"> P</a>]
[<a href="categorylist.cfm?letter=Q"> Q</a>]
[<a href="categorylist.cfm?letter=R"> R</a>]
[<a href="categorylist.cfm?letter=S"> S</a>]
[<a href="categorylist.cfm?letter=T"> T</a>]
[<a href="categorylist.cfm?letter=U"> U</a>]
[<a href="categorylist.cfm?letter=V"> V</a>]
[<a href="categorylist.cfm?letter=W"> W</a>]
[<a href="categorylist.cfm?letter=X"> X</a>]
[<a href="categorylist.cfm?letter=Y"> Y</a>]
[<a href="categorylist.cfm?letter=Z"> Z</a>]<BR>
[<a href="categorylist.cfm"> ALL</a>]
</p>
<!--- Custom tag to display items in three columns down the page --->
<P ALIGN="CENTER">
<cf_columnarlist
query="categorylist"
displayfield="Classification"
maxcolumns="3"
border="1"
width="800"
headercolor="Yellow"
url="displaycategory.cfm?dummy=classification"
addparams="category=classification"
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Get the mailserver that powers this list at http://www.coolfusion.com
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists