Applies to:

  • PHP 5.4
  • MySQL 5.1.4
  • Databases initially setup with collation 'latin1_swedish_ci'

What
Another article trying to help people display foreign characters on their website without the funny question marks in diamond symbols and how I solved it in my case.

What?
A quick article to remind me about this issue. Not sure whether it is specific to the Joomla Content Management System, but within the Joomla! CMS, an error 1054 comes up if you use the above statement.

Why?
The MySQL statement SELECT COUNT(DISTINCT name) FROM table is valid but I get what you mean and it's sometimes difficult to explain why you want to use it.

How?
Method #1: Add an alias to the field:

Well I tried the SQL Server Management Studio solution to connect to a MySQL database then lost my way wondering what was I trying to achieve?

I've written this article because this is how I connected to a MySQL database from within the Business Intelligence Development Studio (BIDS) IDE from Microsoft.

Required:

  • Windows XP (ODBC Data Source Administrator)
  • MS Business Intelligence Development Studio 2008
  • Test/Sample MySQL Database to connect to (server and username + password).
  • Admin Access to the reporting server if you plan on deploying the report to it.
Scenario:
  • We want to report on a MySQL database
  • MySQL login information is a user who exists as a MySQL user and a server user.
  • Reporting server is remote as well as the MySQL database.
  • BIDS is on the client machine.

What?
A quick article on how to populate a database column from another table using a string comparison.

Why?
I have several database tables which replicate country names and I would rather they all use the ccTLD two letter code. This article was written because it took me so long to work it out.

How?

  1.  UPDATE  `table_to_update` a 
  2.          INNER JOIN `table_to_read` b 
  3.              ON a.`CountryName` COLLATE utf8_general_ci LIKE b.`CountryName` COLLATE utf8_general_ci 
  4.  SET     a.`ccTLD` = b.`ccTLD`