forum.coppermine-gallery.net

Support => cpg1.5.x Support => cpg1.5 miscellaneous => Topic started by: dianajameson on October 21, 2011, 06:48:47 pm

Title: Critical Error when viewing pics via "Most Viewed"
Post by: dianajameson on October 21, 2011, 06:48:47 pm
Hi

I have a strange problem.

My huge Coppermine (V1.56 stable) installation works fine - except when I select "Most Viewed" from within an album. When I do this I get the error

"Critical Error" "There was an error while processing a database query"

I have also noticed that on rare occasions when I click a thumbnail the wrong full sized picture is shown.

Any help would be appreciated

Diana
Title: Re: Critical Error when viewing pics via "Most Viewed"
Post by: Αndré on October 21, 2011, 06:56:41 pm
Please enable debug mode and post a link to your gallery.
Title: Re: Critical Error when viewing pics via "Most Viewed"
Post by: dianajameson on October 21, 2011, 08:47:41 pm
HI there

Im afraid I cant post a link to the gallery as it is within the members area of an adult site - Posting the access details here might not be appropriate!

The debug info is

While executing query 'SELECT r.pid, r.aid, filepath, filename, url_prefix, pwidth, pheight, filesize, ctime, r.title, r.keywords, r.votes, pic_rating, hits, caption, r.owner_id, pic_raw_ip, pic_hdr_ip
                FROM cpg11d_pictures AS r
                INNER JOIN cpg11d_albums AS a ON a.aid = r.aid
                WHERE (r.aid = 1997)
                AND approved = 'YES'
                AND hits > 0
                ORDER BY hits ASC, pid DESC
                 LIMIT 0 ,-539' in include/functions.inc.php on line 1593

mySQL error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '-539' at line 8

In file  include/functions.inc.php - Line: 258

Many thanks for your help
Title: Re: Critical Error when viewing pics via "Most Viewed"
Post by: Αndré on October 22, 2011, 08:57:03 pm
If you have the latest release (cpg1.5.16) it's impossible to say what's wrong without blind guessing. I can give you my contact data if you're ready to send me the access details to your members area.