solr-for-wordpress icon indicating copy to clipboard operation
solr-for-wordpress copied to clipboard

Duplicate Results

Open foodnavorg opened this issue 13 years ago • 5 comments

So, after fixing the FF issue and using Chrome I was checking the index. If I do a "Load all Posts" and "Load all Pages" everything works correctly. However, if I then go back and "Update" one of the posts, then it adds a duplicate entry into the index and will give me 2 search results.

If I go back in and update a 2nd time on the same post I'm not getting a 3rd instance of the post in the results index though. If it picks up the Create Post then it's not adding another one on the Update Post. I'm guessing there is some sort of check that is missing in the "Load all Posts/Pages"

Thanks,

foodnavorg avatar Nov 15 '11 02:11 foodnavorg

hmm I just tried to reproduce the above mentioned bug but alas am not having any luck. Can you please this bug still exists with the latest codebase.

shaksi avatar Dec 13 '11 18:12 shaksi

I just completely started over and deleted everything and then reindexed all the posts and pages. Then went in and added a couple spaces to the end of my post on Chipotle Salsa and hit update and I get a separate index result at:

http://foodnav.org/?s=chipotle&submit=Search (took out the duplicate but problem persists also took out my company info stuff, you guys don't want to see that )

It has to be that the datemodified is part of the index.

Jerry E. Craig

-----Original Message----- From: Shakur Shidane [mailto:[email protected]] Sent: Tuesday, December 13, 2011 11:56 AM To: Jerry E. Craig Subject: Re: [solr-for-wordpress] Duplicate Results (#23)

hmm I just tried to reproduce the above mentioned bug but alas am not having any luck. Can you please this bug still exists with the latest codebase.


Reply to this email directly or view it on GitHub: https://github.com/mattweber/solr-for-wordpress/issues/23#issuecomment-3127575

foodnavorg avatar Dec 13 '11 19:12 foodnavorg

Any idea's on this. I know that it's in the post time field, for a "new" post. I'm not really sure how to check that though with an if statement to see if it needs to update or add new. The Logic in the code are completely different. Load all pages doesn't check if the Post exists in the index already, and I have no idea how to bridge that, maybe store the original post date/time and use that to check with doing an add all pages/posts function? Just a thought.

foodnavorg avatar Jan 17 '12 22:01 foodnavorg

It might be that the unique id isn't being built the same way across each post/update. This is the most logical reason I can think of for duplicate entries.

dustinrue avatar Jan 18 '12 02:01 dustinrue

It's the date/time field part of the post. When you load all pages and posts it is using a current time I think for that field instead of the initial date/time that the post was made. That's just what it looked like to me. I'm not sure how or where to change that, but when I looked at the raw xml on the server from the admin panel that was the only field that was different in the 2 entries.

foodnavorg avatar Jan 23 '12 05:01 foodnavorg