![mysql create database utf8 example mysql create database utf8 example](http://www.chicagotech.net/images/mysql4.png)
If you are upgrading, you should perform the UTF-8 migration process (see the Admin page). New installations must be performed into databases that have their default character set as Unicode. It is required that you store all your data in Unicode format (UTF-8). You may see the following error when upgrading your Moodle.
MYSQL CREATE DATABASE UTF8 EXAMPLE FULL
The new database and table will have the latin1 character set by default on a stock MySQL installation, lets confirm this: mysql > SHOW FULL COLUMNS FROM test Mysql > CREATE TABLE test (sometext VARCHAR ( 50 ) ) Lets begin by creating a new database with a simple table: mysql > CREATE DATABASE testmigration
MYSQL CREATE DATABASE UTF8 EXAMPLE OFFLINE
Note that if you are going to migrate a real database, you should run this procedure against an offline backup, not against a live production system. Creating a test databaseįirstly we are going to create a test database for testing the migration process. In this tutorial, I will show you have to convert an existing database and tables from latin1 to the utf8 character set. This is fine for most use cases, however if your application needs to support natural languages that do not use the Latin alphabet (Greek, Japanese, Arabic etc.), then you will need to convert your database to use UTF-8 1 instead. Follow you create a new database on MySQL, the default behaviour is to create a database supporting the latin1 character set.