13299ms a killer but it works

<CFLOOP INDEX="answer_fix"
    LIST="#GETgloss.f_answer#"
    DELIMITERS=" ">
<cfquery name="searchg" datasource="boo" dbtype="ODBC">
SELECT g_id, g_name, g_defination from b_glossary
WHERE (g_name LIKE upper('#answer_fix#'))
</cfquery>
<CFIF searchg.RecordCount>
  <CFOUTPUT><a 
href="gloss_def.cfm?g_id=#searchg.g_id#">#answer_fix#</a></CFOUTPUT>
<CFELSE>
<CFOUTPUT>#answer_fix#</CFOUTPUT>
</CFIF>

</CFLOOP>
Thanks for the push start.
Now I just need to make it a little faster, strip out common words so 
they are not searched for. Would ReplaceNocase be faster, I was not sure 
how?
comments suggestions

Philip Arnold wrote:

>>Could some one point me in right direction or tell me if it
>>is possible?
>>
>>I have a bamboo FAQ that the results are pulled from a data
>>source. What
>>I would like to do is scan the answer field for word matches of a
>>definitions table, then to make that word a active link that would
>>return the definition of the word from the definitions table.
>>any thoughts or comments- or directions?
>>    
>>
>
>There's one "simple" way to handle this...
>
>Loop through the definitions and then use ReplaceNoCase on the output to
>update it with hyperlinks
>
>
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq

Host with the leader in ColdFusion hosting. 
Voted #1 ColdFusion host by CF Developers. 
Offering shared and dedicated hosting options. 
www.cfxhosting.com/default.cfm?redirect=10481

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to