cetch errors like this
Duplicate entry '' for key 2 query: INSERT INTO boost_crawler (url, hash) VALUES ('',''),...
split the query up and retry query only inserting 1 at a time; or maybe having multiple queries in the same db_query() via semicolon ;

CommentFileSizeAuthor
#4 boost-672254.patch3.9 KBmikeytown2
#3 boost-672254.patch2.84 KBmikeytown2

Comments

agence web coheractio’s picture

Hi,
I am also having this issue.
Is this creating an issue in the crawler behavor?
Thanks
Laurent

mikeytown2’s picture

nothing bad happens, just annoying

mikeytown2’s picture

Status: Active » Needs review
StatusFileSize
new2.84 KB

this should prevent the errors

Also experimenting with bypassing php for this

INSERT INTO boost_crawler (url, hash) 

SELECT 
  CONCAT('http://www.example.com/', ua.dst) AS url,
  MD5(CONCAT('http://www.example.com/', ua.dst)) AS hash
FROM url_alias AS ua 
LEFT JOIN node AS n ON n.nid = CAST(substring(ua.src, 6) AS UNSIGNED) 
WHERE (n.status = 1 OR n.status IS NULL)

mikeytown2’s picture

StatusFileSize
new3.9 KB
mikeytown2’s picture

Status: Needs review » Fixed

committed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.