Support » Fixing WordPress » Connection Reset Error – Dont get it!

  • Resolved CallMeAndy

    (@callmeandy)


    Editing a function in functions.php is causing a “connection reset” error on a page. But I cant see why this would be.

    I have made an error in an embedded SQL Script by including a “GROUP BY” in each query (a multisite aggregation) in a multi “UNION” Script.

    Of course the page was displaying, as all the script was doing was listing terms for a taxonomy aggregated across a mutisite.

    The taxonomy is “localities” so by having the “GROUP BY” in the individual queries I am getting two results for Europe etc (well in fact many, not two, as there are many blogs involved in the Union’s)

    So I simply removed the “GROUP BY” element thus: (no other code changed)

    …WHERE post_status = ‘publish’ AND post_type = ‘post’ AND t.taxonomy = ‘localities’ GROUP BY the_slug”;

    changed to

    …WHERE post_status = ‘publish’ AND post_type = ‘post’ AND t.taxonomy = ‘localities'”; //GROUP BY the_slug”;

    Gives the connnection reset error.

    I dont get it – can anybody advise me on this please.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Can you share the whole query here?

    OH sorry didnt see your response – I dont see the relevence to the wider code to be honest however ordinarily if you wanted to see it I would put it up for you. Unfortunatly in this instance the code has changed out of all recognition and I dont seem to have a backup of how it was at that point.

    I have marked this as resolved but in reality it was a workaround.

    Thanks for coming back to me anyway!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Connection Reset Error – Dont get it!’ is closed to new replies.