Members: 16,996
Threads: 38,845
Posts: 159,389
Online: 21

Newest Member: Kl_broka@rediffmail.com


Odoo.tv - Outdoor Television


Sedo - Domains kaufen und verkaufen das Projekt mambers.com steht zum Verkauf Besucherstatistiken von mambers.com etracker® Web-Controlling statt Logfile-Analyse
Old 01.06.2005, 00:09   #1 (permalink)
Baby Mamber
 
Join Date: May 2005
Posts: 5
neilydone is on a distinguished road
Default DB Query: error connecting to database

Hi All,

I've just downloaded DB Query 1.1 for Mambo and I am getting this message when I try and view the queries via the Query function in the Admin console. I am a real newbie when it comes to PHP and MySQL.

The error message is:

DBQ (May 31, 2005, 10:00 pm ): APPLICATION - Could not connect to the database : Access denied for user: \'csirt_hand@localhost\' to database \'www_csirt_handbook_zenwebhosting\'
select `option` as Component, count(*) as 'Menu Items' from mos_components group by `option`

Any help would be gratefully appreciated - DB Query seems to fit my needs really well and I am anxious to get it going!!

Thanks in advance,

Neil
neilydone is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
Old 01.06.2005, 14:12   #2 (permalink)
tcp
Mamber
 
tcp's Avatar
 
Join Date: Dec 2004
Location: US/Romania
Posts: 120
tcp is on a distinguished road
Default Re: DB Query: error connecting to database

This problem relates to the configuration of a database connection. Using the Database Summary screen, you will want to select the database that you are using, and confirm that all the information is correct.

just me,
tcp
__________________
Green Mountain Information Technology Consulting
Specializing in Database Integration
Support for Database Query available here.
tcp is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 01.06.2005, 15:08   #3 (permalink)
Baby Mamber
 
Join Date: May 2005
Posts: 5
neilydone is on a distinguished road
Default Re: DB Query: error connecting to database

Hi thanks - I checked and it all seems to be OK the parameters are the same with regard to the database login, name etc I was given by my hosting company.

Now when I go back to the Databases page from the DB Query drop down manager, I get the following message:

Warning: main(common.class.php): failed to open stream: No such file or directory in /home/.sites/65/site113/web/components/com_dbquery/classes/DBQ/database.class.php on line 12

Fatal error: main(): Failed opening required 'common.class.php' (include_path='') in /home/.sites/65/site113/web/components/com_dbquery/classes/DBQ/database.class.php on line 12

help!

Thanks in advance,

Neil
neilydone is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 01.06.2005, 17:02   #4 (permalink)
tcp
Mamber
 
tcp's Avatar
 
Join Date: Dec 2004
Location: US/Romania
Posts: 120
tcp is on a distinguished road
Default Re: DB Query: error connecting to database

Wow, things seem to be getting worse by the minute.

Can you confirm that the file indicated by the message actually exists?

The line in question is this:
require_once ('common.class.php')
. This line tries to include a file located in the current directory and is usually OK if the PHP include_path settings, specified in php.ini, looks something like this include_path = ".:/var/www/adodb:/usr/share/pear" . The dot ( '.' ) indicates current directory.

However, your include_path isn't very useful, as your error message indicated:
Fatal error: main(): Failed opening required 'common.class.php' (include_path='') ...
. The path is empty.

If you have access to the php installation, I would recommend at least adding the '.' to the include path. If you don't, you may be able to specify it by creating a .htaccess file, as this link discusses.

Alternatively, or in the worse case scenario, you could modify the file dbquery.php and admin.dbquery.php, adding a line such as
ini_set ( "include_path",".:your/new/path" );
.

If you have questions about the PHP installation, you may wish to contact your hosting company and inquire about the best way to modify the include path. Feel free to forward them this message if you wish. I'll be glad to help more but can't offer advice regarding DBQ about how to customize your webserver.

just me,
tcp
__________________
Green Mountain Information Technology Consulting
Specializing in Database Integration
Support for Database Query available here.
tcp is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 01.06.2005, 17:23   #5 (permalink)
Baby Mamber
 
Join Date: May 2005
Posts: 5
neilydone is on a distinguished road
Default Re: DB Query: error connecting to database

Thanks - this is not really clear, as I said I am a bit of a newbie when it comes to PHP/MySQL.

The PHP is working OK for everything else on my Mambo installation.

I've emailed my hosting company techncial support department, but in the meantime, where do I add

ini_set ( "include_path",".:your/new/path" );

in dbquery.php and admin.dbquery.php files? At the start? Will this be ok?

Thanks,

Neil
neilydone is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 01.06.2005, 19:14   #6 (permalink)
Baby Mamber
 
Join Date: May 2005
Posts: 5
neilydone is on a distinguished road
Default Re: DB Query: error connecting to database

OK I figured it out - the schemaname entry was too short.

32 characters is specified as the schemaname vchar field length - however, the database name given to me by my provider was longer than this.

It might be worthwhile considering a higher number of characters for the next version.....

I altered the length of schemaname using mysqlphpadmin to a max of 40 characters and it seems to work OK now.

Phew

Neil
neilydone is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 02.06.2005, 09:58   #7 (permalink)
tcp
Mamber
 
tcp's Avatar
 
Join Date: Dec 2004
Location: US/Romania
Posts: 120
tcp is on a distinguished road
Default Re: DB Query: error connecting to database

Quote:
Originally Posted by neilydone

I altered the length of schemaname using mysqlphpadmin to a max of 40 characters and it seems to work OK now.
Wow! What happened to the days of 'invdb04' or 'acntdbbkup'! I'll change the size of schemaname, username, and password to 48 for DBQ's next release. I'll also work on the path issue. If you want, drop me an e-mail ( gmitc.biz ) and I can send you an early release of 1.2.

Toby
__________________
Green Mountain Information Technology Consulting
Specializing in Database Integration
Support for Database Query available here.
tcp is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 02.06.2005, 12:00   #8 (permalink)
Baby Mamber
 
Join Date: May 2005
Posts: 5
neilydone is on a distinguished road
Default Re: DB Query: error connecting to database

Dear tcp,

Thanks for your responses. I am sorry to say that despite my last post which I thought had fixed the problem (I could view some queries in preview mode) it has reoccured. I've spoken to my hosting Tech support company and they inform me that it is due to a coding issue and something they cannot resolve (as your first post implied). I am at a loss as to what to do now.

I now get the following error:

Warning: main(classes/DBQ/frontend.class.php): failed to open stream: No such file or directory in /home/.sites/65/site113/web/components/com_dbquery/dbquery.php on line 32

Warning: main(): Failed opening 'classes/DBQ/frontend.class.php' for inclusion (include_path='') in /home/.sites/65/site113/web/components/com_dbquery/dbquery.php on line 32

Fatal error: Cannot instantiate non-existent class: dbq_frontend in /home/.sites/65/site113/web/components/com_dbquery/dbquery.php on line 36

If it makes any difference, I cannot seem to alter the permissions on the Components/com_dbquery/ directory - does this have anything to do with the problem? Might I create the directories myself from FTP and then try and move the files in?

The site is www.csirt-handbook.org.uk and you can recreate this error message by clicking on the App v1 menu item on the left.

Cheers,
neilydone is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 02.06.2005, 21:17   #9 (permalink)
tcp
Mamber
 
tcp's Avatar
 
Join Date: Dec 2004
Location: US/Romania
Posts: 120
tcp is on a distinguished road
Default Re: DB Query: error connecting to database

Quote:
Originally Posted by neilydone
Dear tcp,

Thanks for your responses. I am sorry to say that despite my last post which I thought had fixed the problem (I could view some queries in preview mode) it has reoccured. I've spoken to my hosting Tech support company and they inform me that it is due to a coding issue and something they cannot resolve (as your first post implied).
They're wrong, but this doesn't help you. Private message me your e-mail address, if you wish, and I'll send you the latest development release which should fix this problem, as you are not the only one working around tyrannical hosting companies.

just me,
tcp
__________________
Green Mountain Information Technology Consulting
Specializing in Database Integration
Support for Database Query available here.
tcp is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Database Query Version 1.1 Released on Mambo Forge tcp Development Announcements 0 13.05.2005 13:29
database query? boboras Component Development 13 09.04.2005 12:15
how to query a different database ottoplanet Component Development 0 15.03.2005 21:05
Database Query 1.0 Released tcp Development Announcements 0 08.03.2005 16:03
query mysql database for reports using Mambo grieverr Mambo 4.5.1 'How Do I' Questions 0 10.11.2004 00:32


All times are GMT +2. The time now is 10:24.

Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.1.0
A vBSkinworks Design
© Copyright 2004-2008 by Arthur Konze Webdesign.