31.07.2013 Views

MySQL Cluster Tutorial - cdn.oreillystatic.com

MySQL Cluster Tutorial - cdn.oreillystatic.com

MySQL Cluster Tutorial - cdn.oreillystatic.com

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

mysql> select * from employee;<br />

+----+--------------+------------+-------+-------+------+-------------------+<br />

| id | municipality | department | ended | first | last | started |<br />

+----+--------------+------------+-------+-------+------+-------------------+<br />

| 1 | London | 777 | NULL | Billy | Fish | 1st February 2009 |<br />

+----+--------------+------------+-------+-------+------+-------------------+<br />

When allowed to continue, the application creates and persists an additional 100<br />

Employee & Department entities. It then goes on to create and execute a query to find all<br />

employees with a department number of 777 and then looks up the location of the site for<br />

that department.<br />

Department dept;<br />

userTransaction.begin();<br />

for (int i=700;i

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!