User talk:Ragusathis
Add topicNotice: Undefined index: odbc in D:\xampp\htdocs\SNWiki\includes\db\Database.php on line 915[edit source] I am Using MediaWiki 1.24.1
for getting sql server am data adding
require_once "$IP/extensions/OdbcDatabase/OdbcDatabase.php"; include_once "$IP/extensions/ExternalData/ExternalData.php";
$edgDBServerType ['mydb'] = "odbc"; $edgDBServer ['mydb'] = "my_dsn"; $edgDBName ['mydb'] = "UNUSED"; $edgDBUser ['mydb'] = "sa"; $edgDBPass ['mydb'] = "sa@123"; $edgDBTablePrefix ['mydb'] = "dbo";
and i created my_dsn odbc in my windows wiki server in wiki page
{{#get_db_data: db=mydb |from=Testtable |data=test1=test1,test2=test2}}
now submit the page i got a below error message on top of the page
Undefined index: odbc in D:\xampp\htdocs\SNWiki\includes\db\Database.php on line 915 In Database.php the line 915 is below bold line
if ( class_exists( $class ) && is_subclass_of( $class, 'DatabaseBase' ) ) {
$params = array(
'host' => isset( $p['host'] )Â ? $p['host']Â : false,
'user' => isset( $p['user'] )Â ? $p['user']Â : false,
'password' => isset( $p['password'] )Â ? $p['password']Â : false,
'dbname' => isset( $p['dbname'] )Â ? $p['dbname']Â : false,
'flags' => isset( $p['flags'] )Â ? $p['flags']Â : 0,
'tablePrefix' => isset( $p['tablePrefix'] )Â ? $p['tablePrefix']Â : 'get from global',
'schema' => isset( $p['schema'] )Â ? $p['schema']Â : $defaultSchemas[$dbType],
'foreign' => isset( $p['foreign'] )Â ? $p['foreign']Â : false
);
If i type wrong table name in wiki page it showing Below Errors
Notice: Undefined index: odbc in D:\xampp\htdocs\SNWiki\includes\db\Database.php on line 915
Warning: odbc_exec(): SQL error: [Microsoft][SQL Server Native Client 10.0][SQL Server]Invalid object name 'Testtable1'., SQL state S0002 in SQLExecDirect in D:\xampp\htdocs\SNWiki\extensions\OdbcDatabase\OdbcDatabase.body.php on line 26
so i think connectivity is not a problem.
Kindly Help me
-- Ragu
Start a discussion with Ragusathis
Talk pages are where people discuss how to make content on MediaWiki the best that it can be. Start a new discussion to connect and collaborate with Ragusathis. What you say here will be public for others to see.