Last modified: 2007-12-18 15:15:14 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T2585, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 585 - parserTests.php doesn't run on PostgreSQL
parserTests.php doesn't run on PostgreSQL
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
General/Unknown (Other open bugs)
1.12.x
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks: postgres
  Show dependency treegraph
 
Reported: 2004-09-27 04:54 UTC by Brion Vibber
Modified: 2007-12-18 15:15 UTC (History)
2 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Brion Vibber 2004-09-27 04:54:24 UTC
The temporary table creation is currently MySQL-specific.
Comment 1 Wil Mahan 2004-09-27 21:16:52 UTC
Should be fixed now, but I haven't tested it since I don't have PostgreSQL
installed.
Comment 2 Brion Vibber 2004-09-28 10:14:20 UTC
PHP Warning:  pg_query(): Query failed: ERROR:  syntax error at or near "LIKE"
at character 39 in /var/www/html/gres/includes/DatabasePostgreSQL.php on line 99
 
Warning: pg_query(): Query failed: ERROR:  syntax error at or near "LIKE" at
character 39 in /var/www/html/gres/includes/DatabasePostgreSQL.php on line 99
A database error has occurred
Query: CREATE TEMPORARY TABLE parsertestuser LIKE user
Function:
Error: 1 ERROR:  syntax error at or near "LIKE" at character 39
 
Backtrace:
DatabasePostgreSQL.php line 415 calls wfDebugDieBacktrace()
Database.php line 297 calls DatabasePostgreSQL::reportQueryError()
parserTests.php line 316 calls DatabasePostgreSQL::query()
parserTests.php line 280 calls ParserTest::setupDatabase()
parserTests.php line 483 calls ParserTest::setupGlobals()
parserTests.php line 118 calls ParserTest::addArticle()
parserTests.php line 505 calls ParserTest::runTestsFromFile()
Comment 3 Brion Vibber 2004-09-29 07:38:24 UTC
With a couple more tweaks it's running now.
Comment 4 OverlordQ 2007-12-16 18:17:28 UTC
Broken again in r28547:

===
This is MediaWiki version 1.12alpha (r28547).

Reading tests from "maintenance/parserTests.txt"...
Warning: pg_query(): Query failed: ERROR:  relation "searchindex" does not exist in /home/wiki/includes/DatabasePostgres.php on line 542
A database error has occurred
Query: CREATE TEMPORARY TABLE searchindex (LIKE searchindex INCLUDING DEFAULTS)
Function:
Error: 1 ERROR:  relation "searchindex" does not exist

Backtrace:
#0 /home/wiki/includes/Database.php(795): DatabasePostgres->reportQueryError('ERROR:  relatio...', 1, 'CREATE TEMPORAR...', '', false)
#1 /home/wiki/maintenance/parserTests.inc(476): Database->query('CREATE TEMPORAR...')
#2 /home/wiki/maintenance/parserTests.inc(417): ParserTest->setupDatabase()
#3 /home/wiki/maintenance/parserTests.inc(740): ParserTest->setupGlobals()
#4 /home/wiki/maintenance/parserTests.inc(166): ParserTest->addArticle('Main Page', 'blah blah', 34)
#5 /home/wiki/maintenance/parserTests.inc(130): ParserTest->runFile('/home/wiki/main...')
#6 /home/wiki/maintenance/parserTests.php(68): ParserTest->runTestsFromFiles(Array)
#7 {main}
===

AFAIK, according to 'maintenance/postgres/compare_schemas.pl' : "searchindex          ## We use tsearch2 directly on the page table instead"
Comment 5 Greg Sabino Mullane 2007-12-18 15:15:14 UTC
Fixed in r28627, thanks for the report.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links