Verity not searching/returning all fields correctly.

Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.

  1. #1

    Default Verity not searching/returning all fields correctly.

    My web host is running ColdFusion MX 6.1

    I have recently begun constructing Verity collections and indexing them.
    I am having issues in which some records are not being retrieved (when they
    clearly should be).

    For example, I have 21 rows in my database (that has been indexed into a
    Verity collection) that contain the text "St. Lawrence". A text search for
    "St. Lawrence" (with, or without quotation marks) returns only 10 results. Of
    those ten results, not one happens to be one of the records that has "St.
    Lawrence" in the title of the record.

    It is as if Verity isn't searching all of the fields specified in the BODY
    attribute of the CFINDEX tag.
    I know there was a bug in CF5.5 with search strings that contained periods (.)
    and hyphens (-) but I have verified that my web host is running CFMX6.1 ( and I
    was unable to find a fix for 6.1 similar to that listed in the knowledgebase
    for 5.5)

    Here is my code - any suggestions would be much appreciated.

    ----Index code-----





    <CFQUERY NAME="rsProductResults" DATASOURCE="#request.dsn#"
    USERNAME="#request.dsnUsername#" PASSWORD="#request.dsnPassword#">
    SELECT * FROM tbl_products
    </CFQUERY>
    <CFLOCK NAME="products_collection_update" TYPE="EXCLUSIVE" TIMEOUT="30"
    THROWONTIMEOUT="NO">
    <CFINDEX ACTION="REFRESH"
    COLLECTION="product_collection"
    QUERY="rsProductResults"
    KEY="product_id"
    TYPE="CUSTOM"
    BODY="product_name,product_description">
    </CFLOCK>

    ----------------

    ------CFSearch code -------------

    <CFLOCK TYPE="EXCLUSIVE" NAME="EZODSearch" THROWONTIMEOUT="NO" TIMEOUT="30">
    <CFSEARCH
    COLLECTION="ezod_products"
    LANGUAGE="ENGLISH"
    NAME="VerityResults"
    CRITERIA="#lcase('#URL.keywords#')#">
    </CFLOCK>


    <CFPARAM NAME="VerityResults.RecordCount" DEFAULT="0">
    <CFIF VerityResults.RecordCount NEQ 0>
    <CFQUERY NAME="rsGetResults" DATASOURCE="#request.dsn#"
    USERNAME="#request.dsnUsername#" PASSWORD="#request.dsnPassword#">
    SELECT *
    FROM tbl_products
    WHERE product_ID IN (#ValueList(VerityResults.key)#)
    </CFQUERY>
    </CFIF>

    <CFIF rsGetResults.RecordCount NEQ 0>
    <strong><cfoutput>#rsGetResults.RecordCount# results
    found.</cfoutput></strong><BR><BR>
    <CFOUTPUT QUERY="rsGetResults">
    #Product_ID# - <A HREF="Details.cfm?ProdID=#product_ID#">#Product_Na me#</A><BR>
    #Product_ShortDescription#<BR>
    <HR WIDTH="300" ALIGN="LEFT">
    </CFOUTPUT>
    </CFIF>

    Sgt Sarin Guest

  2. Similar Questions and Discussions

    1. Verity for Fast Text Searching Macrochat
      Verity for Fast Text Searching Macrochat Wednesday, August 17, 2005 12:00 PM - 1:00 PM US/Eastern Want to do free text searches like Google in...
    2. Verity Indexing and Searching
      I have used a process for searching Cold Fusion powered sites for years. It's quite simple, really: I create a set of Verity collections pertinent...
    3. Verity - cfsearch not returning results on subsequentgets
      We have no problem returning results from searches with CF server 5. We are now moving to CF Server MX. With an initial search, the result set is...
    4. Using Verity to search BLOB fields in DB
      Hello All! We have an Oracle 9i database with a table containing documents (PDF, Word, Excel, etc) stored in that table in a BLOB column. We want...
    5. #26315 [Opn->Bgs]: mssql_fectch_* functions are returning a space char on empty fields
      ID: 26315 Updated by: iliaa@php.net Reported By: webmaster at cbre dot fr -Status: Open +Status: ...
  3. #2

    Default Re: Verity not searching/returning all fields correctly.

    I am having the same problem trying to build a search engine. The period is throwing everything off. I have multiple fields in 'body' also.

    It seems that any search without the period is ok.
    Chicerjunge Guest

  4. #3

    Default Re: Verity not searching/returning all fields correctly.

    I did want to tell you that using the cf_title does work containing periods. It's like my body isn't picking up the right stuff. Perhaps there is a limit to how much body can take?
    Chicerjunge Guest

  5. #4

    Default Re: Verity not searching/returning all fields correctly.

    I would have to chime in here and state that Verity is broken in V7.

    Here's why:
    I upgraded from v6.1 Std to v7 Std this past weekend. In v6.1 all searching
    worked perfectly for 2+ years. I use collections built from SQL queries
    obtained from MS-Access (I know, I know - don't bash me for using Access, it's
    a client decision).

    As an example, a search on a small 270 recordset containing an ID, question
    and answer is done on the word "Fact". Up pops 15 records. Good. However, a
    search is performed on "Factoid" - no results. In 6.1 both search terms would
    return results, in 7.0 only the word "Fact" returns results. The data was
    entered by the client in January 2005, so we know it was working for several
    months.

    Problem solving on my end:

    1) deleting and recreating the collections in the Cfadmin area, and reindexing
    the collections - no resolution.
    2) Installing the CFMX7 hotfix 2, which addresses some verity problems.
    Restart CFMX7, delete and recreate collections from CFAdmin console,
    reindexing the collections - no resolution.
    3) Deleting the actual record from the db, then reinserting the record as new,
    then reindexing - no resolution.
    FYI - prior to reindexing, the Access db is compacted to make sure there are
    no errors.

    Here's the actual question text for this record:

    Fact or Factoid - the addition of copper pennies to vase water increases the
    life of tulips?

    What's really weird is that this phrase will not even show up in the search
    for "fact". Hmm, does the non-Unicode of this MS-access db have an effect?

    Here's the code I use for indexing and searching (I have made no changes to
    this code in 2+ years of use):

    <!---Index the contents of the query object using CFINDEX---> <cflock
    name="cfindexFAQ_lock" type="EXCLUSIVE" TIMEOUT="30">
    <CFINDEX ACTION="REFRESH"
    COLLECTION="faq_db"
    KEY="faq_ID"
    TYPE="CUSTOM"
    TITLE="question"
    QUERY="indexdb"
    BODY="question,answer"
    LANGUAGE="English">
    </cflock>

    <cfsearch collection="faq_db" NAME="v_faq" TYPE="SIMPLE"
    CRITERIA="#FORM.criteria#">

    Anyone else having these problems? Is this a bug, or are there code changes
    in the cfindex routine that I need to tweak from 6.1 to 7.0?

    If this can't be fixed, is there a way to run 6.1 Verity again, disable 7.0
    verity, but keep 7.0 as the primary application server?


    mleder4 Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139