Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. Download MySQL Community Server of MySQL Community Edition, version 5.6 or later, and follow the installation instructions including the postinstallation setup and testing.
  2. MySQL gets installed to /usr/local/mysql-VERSION and also installs a symbolic link, /usr/local/mysql, that points to the new location.  By default, MySQL is set up with only a root account with no password.
  3. Ensure the MySQL bin folder has been added to your PATH environment variable:
    • In TextEdit, navigate to your home folder (~ or /Users/<yourname>).
    • From the File menu, choose Open.
    • Press Cmd + Shift + . so that hidden files are shown, and select the .profile file.
    • Add the following line:

      Code Block
      languagetext
      themeDJango
      linenumberstrue
      export PATH=$PATH:/usr/local/mysql/bin
    • (info) You can also edit the .bash_profile file as done above using VI and add a line that appends /usr/local/mysql/bin to the PATH environment variable.
    • If you have a Terminal window open, be sure to close it and open a new one so that the PATH change takes effect.
  4. Download the attached CreateExamplegearDatabase_v1.sql file to your local machine.
  5. In the Terminal window,
    1. Navigate to the directory to which you downloaded the the attached CreateExamplegearDatabase_v1.sql file.
    2. Go into the mysql command line program as the root user by executing the following command

    in a Terminal window
    1. :

      Code Block
      languagetext
      themeDJango
      linenumberstrue
      mysql -u root mysql
    2. At the mysql

    Download the attached
    1. prompt, execute the following command to create the database and populate it with data.

      Code Block
      source CreateExamplegearDatabase_v1.sql
  6. At this point you should have the following:
    1. A MySQL database named examplegeardb.
    2. A user account dbuser with a password of mypassword.
    3. These tables:
      1. Addresses
      2. Customers
      3. Departments
      4. Employees
      5. LineItems
      6. Products
      7. Ref_AddressTypeCode
      8. Ref_CountryCode
      9. Ref_EmployeeStatusCode
      10. Ref_OrderStatusCode
  7. To support running SQL queries against the examplegeardb database using the SQL for Confluence (Express Edition) add-on or SQL for Confluence (Pro Edition) add-on, build a data source profile with the following information:
Section
Column
width50px

 

Column
Name:examplegeardb
Value:dbUrl=jdbc:mysql://localhost:3306/examplegeardb?useUnicode=true&amp;characterEncoding=utf8&amp;allowMultiQueries=true|dbUser=dbuser|dbPassword=mypassword|dbDriver=com.mysql.jdbc.Driver|dbJar=http://central.maven.org/maven2/mysql/mysql-connector-java/5.1.34/mysql-connector-java-5.1.34.jar