This question about Using an extension: Closed unanswered

Remote Database Config for DB Connection Information

Hi,

I'm attempting to configure this plugin to use a mysql database to gather the db connection info:

I've filled out the configuration, here is the out from the LocalSite.cfg:

$Foswiki::cfg{Plugins}{DatabasePlugin}{Enabled} = 1;
$Foswiki::cfg{Plugins}{DatabasePlugin}{Module} = 'Foswiki::Plugins::DatabasePlugin';
$Foswiki::cfg{Plugins}{DatabasePlugin}{ConfigSource} = 'Remote';
$Foswiki::cfg{Plugins}{DatabasePlugin}{ConfigHost} = 'localhost';
$Foswiki::cfg{Plugins}{DatabasePlugin}{ConfigDriver} = 'mysql';
$Foswiki::cfg{Plugins}{DatabasePlugin}{ConfigDB} = 'wiki';
$Foswiki::cfg{Plugins}{DatabasePlugin}{ConfigSID} = 'wiki';
$Foswiki::cfg{Plugins}{DatabasePlugin}{ConfigTable} = 'db_connection';
$Foswiki::cfg{Plugins}{DatabasePlugin}{ConfigUsername} = 'wiki_user';
$Foswiki::cfg{Plugins}{DatabasePlugin}{ConfigPassword} = 'wikiwiki';
$Foswiki::cfg{Plugins}{DatabasePlugin}{EditURLPrefix} = 'https';
$Foswiki::cfg{Plugins}{DatabasePlugin}{EditURLPath} = 'phpMyAdmin-2.2.2-rc1';

Here is a query from mysql database:

mysql> use wiki

mysql> select * from db_connection;

+-------------+--------+---------+--------+-------------+-------------+---------------------+------------+
| description | driver | db_name | db_sid | ro_username | ro_password | hostname| table_name |
+-------------+--------+---------+--------+-------------+-------------+---------------------+------------+
| devdb | Oracle | devdb | devdb | query_user | query_user | devdb.tare.local | NULL |
+-------------+--------+---------+--------+-------------+-------------+---------------------+------------+

My page returns:

Can't call method "prepare" on an undefined value at /TARe/wiki/twiki/twiki_dev/lib/Foswiki/Plugins/DatabasePlugin.pm line 57.
at /TARe/wiki/twiki/twiki_dev/lib/Foswiki/Plugins/DatabasePlugin.pm line 57
Foswiki::Plugins::DatabasePlugin::initPlugin('MoscardiniEdward', 'Main', 'emoscard', 'System') called at /TARe/wiki/twiki/twiki_dev/lib/Foswiki/Plugin.pm line 231
Foswiki::Plugin::registerHandlers('Foswiki::Plugin=HASH(0x9d3177c)', 'Foswiki::Plugins=HASH(0x94431e4)') called at /TARe/wiki/twiki/twiki_dev/lib/Foswiki/Plugins.pm line 244
Foswiki::Plugins::enable('Foswiki::Plugins=HASH(0x94431e4)') called at /TARe/wiki/twiki/twiki_dev/lib/Foswiki.pm line 1538
Foswiki::new('Foswiki', 'undef', 'Foswiki::Request=HASH(0x9050f70)', 'HASH(0x93f8254)') called at /TARe/wiki/twiki/twiki_dev/lib/Foswiki/UI.pm line 276
Foswiki::UI::_execute('Foswiki::Request=HASH(0x9050f70)', 'CODE(0x9405128)', 'view', 1) called at /TARe/wiki/twiki/twiki_dev/lib/Foswiki/UI.pm line 258
Foswiki::UI::handleRequest('Foswiki::Request=HASH(0x9050f70)') called at /TARe/wiki/twiki/twiki_dev/lib/Foswiki/Engine/CGI.pm line 26
Foswiki::Engine::CGI::run('Foswiki::Engine::CGI=HASH(0x92c2a98)') called at /TARe/wiki/twiki/twiki_dev/bin/view line 45

I've switched it over to "Local" and configured the local DBI sucessfully without issues.

I just can't seem to be able to get the "Remote" to work. Any sugestions would be appreciated!!

Thanks!

-- EdwardMoscardini - 13 Jul 2009

Closing this ticket due to inactivity. Please re-open, if necessary.

-- OliverKrueger - 09 Oct 2009

QuestionForm edit

Subject Using an extension
Extension DatabasePlugin
Version Foswiki 1.0.5
Status Closed unanswered
Topic revision: r2 - 09 Oct 2009, OliverKrueger - This page was cached on 19 Oct 2018 - 05:24.

The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy