Topic on Project:Support desk

94.113.242.66 (talkcontribs)

Hi all,

I'm running MW1.17 on IIS7 and MySQL server for now. I need to move the database to our company Microsoft SQL Server 2008.

I tried the MS Migration Assistant, but it failed.

In the SQL Management Studio I tried to import the table definitions form maintenance/mssql/tables.sql, but it failed with error Msg 156, Level 15, State 1, Line 33 Incorrect syntax near the keyword 'user'.

Can somebody help me?

89.167.129.50 (talkcontribs)

Hi, you have to modify the file Database.php, function: fieldNameWithAlias, line 2566, you have to put the brackets in the alias.

return $name . ' AS ' . $alias;

for this

return $name . ' AS [' . $alias.']';

a bit late, lol

31.150.179.230 (talkcontribs)

Honestly, I would say: You have to install MySQL. While MediaWiki should theoretically support MSSQL, this support compared to MySQL is way less mature. You should expect a variety of things to be not working or having bad performance, just because not so many people use MediaWiki with MSSQL and because it's optimized for MySQL, likely with InnoDB tables in mind.

So, if you want to solve this issue properly, use MySQL. This is the real fix.

Reply to "Moving to MSSQL"