[Wikitech-l] correct way to import SQL dumps into MySQL database in terms of character encoding

2012-04-01 Thread Piotr Jagielski
Hello, I'm trying to import categorylinks.sql dump into my MySQL database. I'm able to import it and query for articles in specific categories as long the category name contains only English-language characters. I don't get any results if I try to query for non-English category name. My

Re: [Wikitech-l] correct way to import SQL dumps into MySQL database in terms of character encoding

2012-04-01 Thread Svip
On 1 April 2012 16:04, Piotr Jagielski piotr.jagiel...@op.pl wrote: mysql --user root --password=root wiki C:\Path\plwiki-20111227-categorylinks.sql --default-character-set=utf8 It's -p, not --password=root and it will prompt you for the password.

Re: [Wikitech-l] correct way to import SQL dumps into MySQL database in terms of character encoding

2012-04-01 Thread Piotr Jagielski
These options should be equivalent. It does load the data using the below command. It just incorrectly handles non-English characters. Regards, Piotr On 2012-04-01 16:31, Svip wrote: On 1 April 2012 16:04, Piotr Jagielskipiotr.jagiel...@op.pl wrote: mysql --user root --password=root wiki

Re: [Wikitech-l] correct way to import SQL dumps into MySQL database in terms of character encoding

2012-04-01 Thread Platonides
On 01/04/12 17:05, Piotr Jagielski wrote: These options should be equivalent. It does load the data using the below command. It just incorrectly handles non-English characters. Regards, Piotr Do you have $wgDBmysql5 set in your LocalSettings.php?

Re: [Wikitech-l] correct way to import SQL dumps into MySQL database in terms of character encoding

2012-04-01 Thread Piotr Jagielski
I don't have MediaWiki installed. I'm just trying to import the dump into a standalone database so I can do some batch processing on the data. Regards, Piotr On 2012-04-01 17:30, Platonides wrote: On 01/04/12 17:05, Piotr Jagielski wrote: These options should be equivalent. It does load the

Re: [Wikitech-l] correct way to import SQL dumps into MySQL database in terms of character encoding

2012-04-01 Thread Marcin Cieslak
Piotr Jagielski piotr.jagiel...@op.pl wrote: Hello, set my data source URL to the following in my Java code: jdbc:mysql://localhost/plwiki?useUnicode=truecharacterEncoding=UTF-8 Please note you have plwiki here and you imported into wiki. Assuming your .my.cnf is not making things difficult

Re: [Wikitech-l] correct way to import SQL dumps into MySQL database in terms of character encoding

2012-04-01 Thread Piotr Jagielski
Sorry, I made a mistake in the e-mail. I had the database set to the same name in both places. My problem is actually opposite because I don't get any result where I use UTF-8 string as an input in the query. But I verified that I don't get correct results where using the query you provided

Re: [Wikitech-l] correct way to import SQL dumps into MySQL database in terms of character encoding

2012-04-01 Thread Platonides
On 01/04/12 17:37, Piotr Jagielski wrote: I don't have MediaWiki installed. I'm just trying to import the dump into a standalone database so I can do some batch processing on the data. Regards, Piotr It inserts the data fine for me. I suspect your java code is failing to appropiately read