Extension talk:SQL2Wiki

From MediaWiki.org
Jump to: navigation, search
Start a new discussion

Contents

Thread titleRepliesLast modified
Missing or invalid type322:06, 16 December 2011
Problem: parameter in template016:16, 22 July 2011
Dynamic Query and Pagination mods didn't make it in...107:49, 14 June 2011

Missing or invalid type

I am using MW 1.16.2, my database is mysql,

on the page: Special:SQL2Wiki I have the error massage: Missing or invalid type,
and a query results in a blank page
in LocalSettings I wrote: $wgExSql2WikiDatabases["db1"] = array( "type"=> "mysql", "host" => "localhost", "dbname" => "myname", "user" => "myuser", "password" => "mypass");
( I am still using the old version of sql2wiki as xsql2wiki, and it works fine)
thank you
Agapetulus09:37, 9 December 2011

Hi, I don't think I can help you, as I don't have $wgExSql2WikiDatabases anywhere in my system.

I think you must be working on a branch of the SQL2Wiki.php that I worked on.

Bytesmiths01:33, 16 December 2011

Hello, thank you for the answer,

I'm confused, on the Extension page I can read :

3. Specify databases you want to access into

$wgExSql2WikiDatabases["db1"] = array( "type"=> "oracle", "host" => "tnsname", "dbname" => "scott", "user" => "scott", "password" => "tiger");

in my LocalSettings I wrote:

$wgExSql2WikiDatabases["db1"] = array( "type"=> "mysql", "host" => "localhost", "dbname" => "myname", "user" => "myuser", "password" => "mypass");

why shouldn't there be a $wgExSql2WikiDatabases ?, or did I get something wrong?

unfortunatly I cannot work on your branch of the SQL2Wiki, (things might change after a update of my mediawiki in January)...

in any case I wish you a merry christmas, and a happy new year

Agapetulus14:46, 16 December 2011

My version has the database information embedded in the extension -- which I admit is not wonderful.

Good luck with your problem, and if you become interested in my version (which has some interesting mods that never got into the version posted here, like ability to query and paginate), let me know.

Bytesmiths22:06, 16 December 2011
 
 
 

Problem: parameter in template

Sugestion:

In "SQL2Wiki.body.php", replace:

$sql = ( $s2w->shouldPreexpand() ) ? $parser->recursiveTagParse( $input ) : $input;

by:

$sql = ( $s2w->shouldPreexpand() ) ? $parser->recursiveTagParse( $input, $frame ) : $input;

See: http://www.mediawiki.org/wiki/Manual:Tag_extensions#Extensions_and_Templates

Thanks.

-- Alexandre Porto msg16:16, 22 July 2011

Dynamic Query and Pagination mods didn't make it in...

I see my dynamic query mod ("where=") didn't make it in. Nor did my pagination mod ("count="). Sigh.

The latter is absolutely essential if you expect a large number of hits on a query.

These mods are at: Extension_talk:SQL2Wiki/old#Use_with_Extension:InputBox.3F

--Bytesmiths 18:12, 6 June 2011 (UTC)

Bytesmiths18:12, 6 June 2011

ufff ... branched from that extension so long ago that i failed to notice the Talk page ... will have a look at it.

Freakolowsky07:49, 14 June 2011