Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: [1]   Go Down

Author Topic: [Solved]: There was an error while processing a database query?  (Read 25514 times)

0 Members and 1 Guest are viewing this topic.

forummaker

  • Coppermine newbie
  • Offline Offline
  • Posts: 17
    • RemedyDog.com

I have the following issue when trying to bridge coppermine and SMF 1.1.5:
There was an error while processing a database query

Coppermine install: http://www.remedydog.com/coppermine
Forum install: http://www.remedydog.com/forums
Coppermine version: cpg1.4.8
Forum version: SMF 1.1.5
Test user account: joe / joee

BridgeManager settings:
Forum URL:  http://www.remedydog.com/forums
Relative path to your BBS's config file:  ../forums/
Use post-based groups?:  yes
Cookie name/preifx (if applicable)

After bridging smf and coppermine I created an account in the forum to test and see if it would auto login to coppermine. Now I'm getting "There was an error while processing a database query" all over coppermine. Any help would be appreciated. Thanks.
« Last Edit: July 03, 2008, 01:19:19 am by Nibbler »
Logged
Remedydog.com
Where dogs would go if they could talk

Nibbler

  • Guest
Logged

forummaker

  • Coppermine newbie
  • Offline Offline
  • Posts: 17
    • RemedyDog.com
Re: There was an error while processing a database query?
« Reply #2 on: June 28, 2008, 04:55:22 pm »

USER:
------------------
Array
(
    [ID] =>
    [am] => 1
    [lang] => english
)

==========================
USER DATA:
------------------
Array
(
    [user_id] =>
    [user_name] =>
    [groups] => Array
        (
           
  • => 2
  • [1] => 100
            )

        [disk_max] => 1024
        [disk_min] => 1024
       
[can_rate_pictures] => 1
    [can_send_ecards] => 1
    [ufc_max] => 3
    [ufc_min] => 3
    [custom_user_upload] => 0
    [num_file_upload] => 5
    [num_URI_upload] => 3
    [can_post_comments] => 1
    [can_upload_pictures] => 1
    [can_create_albums] => 0
    [has_admin_access] => 0
    [pub_upl_need_approval] => 1
    [priv_upl_need_approval] => 0
    [group_name] => Registered
    [upload_form_config] => 3
    [group_quota] => 1024
    [can_see_all_albums] => 0
    [group_id] => 2
)

==========================
Queries:
------------------
Array
(
   
  • => SELECT extension, mime, content, player FROM cpg14x_filetypes; (0.001s)
  • [1] => select * from cpg14x_plugins order by priority asc; (0.001s)
        [2] => SELECT * FROM cpg14x_bridge (0.001s)
        [3] => SELECT MAX(group_quota) as disk_max, MIN(group_quota) as disk_min, MAX(can_rate_pictures) as can_rate_pictures, MAX(can_send_ecards) as can_send_ecards, MAX(upload_form_config) as ufc_max, MIN(upload_form_config) as ufc_min, MAX(custom_user_upload) as custom_user_upload, MAX(num_file_upload) as num_file_upload, MAX(num_URI_upload) as num_URI_upload, MAX(can_post_comments) as can_post_comments, MAX(can_upload_pictures) as can_upload_pictures, MAX(can_create_albums) as can_create_albums, MAX(has_admin_access) as has_admin_access, MIN(pub_upl_need_approval) as pub_upl_need_approval, MIN( priv_upl_need_approval) as  priv_upl_need_approval FROM cpg14x_usergroups WHERE group_id in (2,100) (0.001s)
        [4] => SELECT group_name FROM  cpg14x_usergroups WHERE group_id= 2 (0.001s)
        [5] => DELETE FROM cpg14x_banned WHERE expiry < '2008-06-28 14:54:12' (0.001s)
        [6] => SELECT * FROM cpg14x_banned WHERE (ip_addr='68.29.10.26' OR ip_addr='68.29.10.26' OR user_id=) AND brute_force=0 (0s)
    )

    ==========================
    GET :
    ------------------
    Array
    (
       
[e] =>
)

==========================
POST :
------------------
Array
(
)

==========================
Page generated in 0.236 seconds - 7 queries in 0.006 seconds - Album set : ; Meta set: ;
Logged
Remedydog.com
Where dogs would go if they could talk

forummaker

  • Coppermine newbie
  • Offline Offline
  • Posts: 17
    • RemedyDog.com
Re: There was an error while processing a database query?
« Reply #3 on: July 01, 2008, 03:52:56 am »

Sorry, but now I have a different problem, and still get the same error. Now when a guest clicks on an image from my homepage it takes them to my coppermine site, but it displays the error.  It works fine if someone is logged into the site and clicks the image. I thought I set all the proper permissions in the control panel, not sure what I missed. Thanks in advance.
Logged
Remedydog.com
Where dogs would go if they could talk

Nibbler

  • Guest
Re: There was an error while processing a database query?
« Reply #4 on: July 01, 2008, 03:57:04 am »

You need to enable debug mode. Can't help you otherwise.
Logged

forummaker

  • Coppermine newbie
  • Offline Offline
  • Posts: 17
    • RemedyDog.com
Re: There was an error while processing a database query?
« Reply #5 on: July 01, 2008, 04:12:41 am »

USER:
------------------
Array
(
    [ID] =>
    [am] => 1
    [lang] => english
    [liv] => Array
        (
           
  • => 5

        )

)

==========================
USER DATA:
------------------
Array
(
    [user_id] =>
    [user_name] =>
    [groups] => Array
        (
           
  • => 2

        )

    [disk_max] => 6000
    [disk_min] => 6000
    [can_rate_pictures] => 1
    [can_send_ecards] => 1
    [ufc_max] => 3
    [ufc_min] => 3
    [custom_user_upload] => 0
    [num_file_upload] => 3
    [num_URI_upload] => 1
    [can_post_comments] => 1
    [can_upload_pictures] => 1
    [can_create_albums] => 0
    [has_admin_access] => 0
    [pub_upl_need_approval] => 0
    [priv_upl_need_approval] => 0
    [group_name] => Registered
    [upload_form_config] => 3
    [group_quota] => 6000
    [can_see_all_albums] => 0
    [group_id] => 2
)

==========================
Queries:
------------------
Array
(
   
  • => SELECT extension, mime, content, player FROM cpg14x_filetypes; (0.001s)
  • [1] => select * from cpg14x_plugins order by priority asc; (0.001s)
        [2] => SELECT * FROM cpg14x_bridge (0.001s)
        [3] => SELECT MAX(group_quota) as disk_max, MIN(group_quota) as disk_min, MAX(can_rate_pictures) as can_rate_pictures, MAX(can_send_ecards) as can_send_ecards, MAX(upload_form_config) as ufc_max, MIN(upload_form_config) as ufc_min, MAX(custom_user_upload) as custom_user_upload, MAX(num_file_upload) as num_file_upload, MAX(num_URI_upload) as num_URI_upload, MAX(can_post_comments) as can_post_comments, MAX(can_upload_pictures) as can_upload_pictures, MAX(can_create_albums) as can_create_albums, MAX(has_admin_access) as has_admin_access, MIN(pub_upl_need_approval) as pub_upl_need_approval, MIN( priv_upl_need_approval) as  priv_upl_need_approval FROM cpg14x_usergroups WHERE group_id in (2) (0.001s)
        [4] => SELECT group_name FROM  cpg14x_usergroups WHERE group_id= 2 (0s)
        [5] => SELECT * FROM cpg14x_final_extract_config (0.001s)
        [6] => DELETE FROM cpg14x_banned WHERE expiry < '2008-07-01 02:11:15' (0.001s)
        [7] => SELECT * FROM cpg14x_banned WHERE (ip_addr='68.30.184.193' OR ip_addr='68.30.184.193' OR user_id=) AND brute_force=0 (0s)
    )

    ==========================
    GET :
    ------------------
    Array
    (
       
[pos] => -4
    [e] =>
    [displayimage_php?pos] => -4
)

==========================
POST :
------------------
Array
(
)

==========================
Page generated in 0.251 seconds - 8 queries in 0.006 seconds - Album set : ; Meta set: ;
Logged
Remedydog.com
Where dogs would go if they could talk

forummaker

  • Coppermine newbie
  • Offline Offline
  • Posts: 17
    • RemedyDog.com
Re: There was an error while processing a database query?
« Reply #6 on: July 01, 2008, 04:16:02 am »

While executing query "SELECT * FROM cpg14x_banned WHERE (ip_addr='' OR ip_addr='' OR user_id=) AND brute_force=0" on 0

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 ') AND brute_force=0' at line 1
Logged
Remedydog.com
Where dogs would go if they could talk

Nibbler

  • Guest
Re: There was an error while processing a database query?
« Reply #7 on: July 01, 2008, 04:48:42 am »

Edit include/init.inc.php

find

Code: [Select]
$user_id = USER_ID;
change to

Code: [Select]
$user_id = USER_ID ? USER_ID : 0;
Logged

forummaker

  • Coppermine newbie
  • Offline Offline
  • Posts: 17
    • RemedyDog.com
Re: There was an error while processing a database query?
« Reply #8 on: July 03, 2008, 12:41:26 am »

Thanks! Worked great. I'm getting something else. I'm getting these errors in my smf error logs. Any ideas?

Here are two error logs:

"2: mysql_query() [<a href='function.mysql-query'>function.mysql-query[/url]]: A link to the server could not be established
File: /home/content/j/u/m/html/forums/Themes/default/TPortal.template.php (tp_below sub template - eval?)
Line: 176:"

"8: Undefined property: cpm::$ AND ( p.filename like '%.jpg' OR p.filename like '%.JPG' OR
File: /home/content/j/u/m/html/coppermine/cpmfetch/cpmfetch_dao.php
Line: 182"
Thank you very much for the help.
Logged
Remedydog.com
Where dogs would go if they could talk

Nibbler

  • Guest
Re: There was an error while processing a database query?
« Reply #9 on: July 03, 2008, 01:18:33 am »

I don't think that's related. I reported the second issue at http://forum.coppermine-gallery.net/index.php/topic,53647.0.html however.
Logged
Pages: [1]   Go Up
 

Page created in 0.021 seconds with 19 queries.