cfindex shows records inserted but doccount is 0

78 Views Asked by At

I'm using cfindex on a query but I can't get the data out of the index. My other indexes have a doccount greater than 0 when I check their collections, but this one is always 0 even though the status of the refresh has a value. Here is my code:

<cfindex
    action="refresh"
    collection="quizzes"
    body="quiz,course,courseName,quizName,inClass,unlock_at,lock_at,type"
    query="qExams"
    type="custom"
    key="quiz"
    status="info" />
<cfdump var="#info#" />
<cfcollection 
    name="qQuizzes"
    action="list" />
<cfdump var="#qQuizzes#"/>
<cfabort/>

I don't think there is any reason to show the query that creates qExams, but I've dumped it before the index and I do note there there is indeed data in it.

The result of #info# is the following:

struct
DELETED  0
INSERTED 1154
UPDATED  0

The result of #qQizzes# is the following:

    DOCCOUNT    LASTMODIFIED    NAME    PATH    SIZE
  1   53            [date]      faq     [path]  144
  2  4892           [date]     courses  [path]  6777
  3    0            [date]     quizzes  [path]  838

I removed the paths and dates just for clarity. But as you can see the size is not 0 and it even changes if I say add or remove custom fields in the index, however the doccount is always 0.

What would cause this to be 0 every time?

0

There are 0 best solutions below