<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Tim Keller &#187; mysql</title>
	<atom:link href="http://timk.co.za/tag/mysql/feed/" rel="self" type="application/rss+xml" />
	<link>http://timk.co.za</link>
	<description>Web, IT, Telecoms, Development, Networks, Photography, Life.</description>
	<lastBuildDate>Sat, 10 Jul 2010 12:49:31 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>uniti successfully deployed for the Soccer World Cup</title>
		<link>http://timk.co.za/2010/07/10/uniti-successfully-deployed-for-the-soccer-world-cup/</link>
		<comments>http://timk.co.za/2010/07/10/uniti-successfully-deployed-for-the-soccer-world-cup/#comments</comments>
		<pubDate>Sat, 10 Jul 2010 12:43:58 +0000</pubDate>
		<dc:creator>Tim Keller</dc:creator>
				<category><![CDATA[Geek]]></category>
		<category><![CDATA[Professional]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Chirp]]></category>
		<category><![CDATA[disaster management]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[staffroom]]></category>
		<category><![CDATA[umoya]]></category>
		<category><![CDATA[uniti]]></category>

		<guid isPermaLink="false">http://timk.co.za/?p=62038345</guid>
		<description><![CDATA[I&#8217;ve been rather quiet of late &#8211; here&#8217;s why: Our team at Umoya have been hard at work on supplying our uniti app to the National Disaster Management Centre for 2010.
In September 2009, we starting building Umoya&#8217;s next software platform using staffroom (our school management app) as a base. We distilled the framework down to [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been rather quiet of late &#8211; here&#8217;s why: Our team at Umoya have been hard at work on supplying our <em>uniti</em> app to the National Disaster Management Centre for 2010.</p>
<p>In September 2009, we starting building Umoya&#8217;s next software platform using staffroom (our school management app) as a base. We distilled the framework down to its core, and called it the ChirpFramework (a reference to staffroom&#8217;s original name &#8211; ChirpSchool). We chose PHP on the front-end so that our developers could rapidly deploy new features, and MySQL on the backend as we understand its performance characteristics in staffroom. In between, we have some bits holding things together.</p>
<p>Since November we&#8217;ve been actively developing <em>uniti</em> &#8211; our unified collaboration app for business and government. Here&#8217;s some more about it:</p>
<blockquote><p>DISASTER management centres around the country will use software developed for the World Cup to coordinate a multi-disciplinary, multi-sectoral approach to expected xenophobic attacks and their consequences.</p>
<p>The need to manage the risk of disasters during the World Cup prompted the Western Cape Disaster Management Centre to ask Cape Town ICT company, Umoya (www.umoya.net), to devise a web-based platform that has since streamlined emergency communications country-wide.</p>
<p>Known as &#8220;uniti&#8221;, the software helped more than 350 disaster management workers, including command and control centres, to share real-time information that provided up-to-the minute readiness to deal with any eventuality during the World Cup said Peter Beretta of Umoya.</p>
<p>“The National Disaster Management Centre has procured the program for operations in all provinces, where it is being used by Disaster Management themselves, as well as elements from the police, Red Cross and other government entities,” said Beretta</p>
<p>Jackson Rikhotso, Western Cape provincial deputy director responsible for disaster preparedness, said the &#8220;uniti&#8221; software “helps us to get accurate information for proper decision making”.</p>
<p>“It contributed to the smooth running of the World Cup,” said Rikhotso.</p>
<p>Hailing Uniti as a “major milestone”, Mlungisi Gongqa from the national Disaster Management Centre in Pretoria said: “For the first time in the history of national disaster management we are able to network with everybody across the country, and improve response time.</p>
<p>“We can report and analyse situations more quickly.”</p>
<p>Gongqa said on Friday: “We are already plugged into Uniti in all the provinces so it will be easy for picking up xenophobic incidents as they arise from municipality to municipality and from province to province.</p>
<p>“We will use Uniti to log in every incident of xenophobia, and will follow up on every one of them, no matter how small.”</p>
<p>Andre Harrison, also of Umoya, said: “Although Uniti was developed for the World Cup, it has legs beyond that. To help the country cope with attacks and their consequences, the system can be developed further to make it more specific for the needs that arise out of the displacement of people. As these events occur, the software is able to develop in synch with what is happening.”</p>
<p>Beretta said Uniti facilitated communication between line functions like police, ambulance and fire services, and was already being used by some district and local municipalities, including the City of Cape Town.</p>
<p>The management of refugee camps was being developed to link all the camps and their managers, who could communicate with each other easily and quickly.</p>
<p>“Camps that have the Uniti software will, because of their integrated communication, be able to register the refugees in and out of camps, keep full biographical details of displaced persons, and provide accreditation details of NGOs, social workers and people working in the camps.</p>
<p>“The software also facilitates the transferring of people between camps. It is able to link family members in different camps. Part of the software is a web presence that allows details of missing persons to be published on the website.</p>
<p>uniti’s core is the thousands of contacts it provides of individuals in all areas able to respond when disaster threatens.</p>
<p>“A centralised address book of all relevant disaster management, police, emergency services, defence force and fire department staff makes it possible to reach the relevant person when necessary,” Beretta said.</p>
<p>“Your data base gives you the name of the relevant individuals, contact details and photographs of each. All you need do is click on ‘call’,  and the program dials your landline or cell phone while calling the other person.”</p>
<p>The &#8220;uniti&#8221; system includes the ability to listen in on or join two-way radio talk groups, voice recording, situation report logs, a forum for text conversations, and a web intranet facility for posting alerts, updates and images. It also plots the recorded incidents using Google Maps.</p>
<p>“It is already being used daily for communication between Disaster Management and emergency services. The program allows everyone to know when and where anything is happening. We get several hundred entries a day from users.</p>
<p>“We have designed it so that it is mobile. You can access it from your cell phone or a laptop and it is rapidly-deployable anywhere because it is a hosted application and only requires access to the internet.”</p>
<p>It takes two hours to train someone to use the system, he said.</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://timk.co.za/2010/07/10/uniti-successfully-deployed-for-the-soccer-world-cup/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Comparing two MySQL tables</title>
		<link>http://timk.co.za/2010/02/01/comparing-two-mysql-tables/</link>
		<comments>http://timk.co.za/2010/02/01/comparing-two-mysql-tables/#comments</comments>
		<pubDate>Mon, 01 Feb 2010 15:05:52 +0000</pubDate>
		<dc:creator>Tim Keller</dc:creator>
				<category><![CDATA[Geek]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[Opensource]]></category>
		<category><![CDATA[sql]]></category>

		<guid isPermaLink="false">http://timk.co.za/?p=62038231</guid>
		<description><![CDATA[From time to time, I need to compare MySQL database tables and see what data has been added to the one in the time since I mysqldump&#8217;d the first one.
For example: Let&#8217;s say I have table_a as my snapshot&#8217;d table, and table_b as my newer table which has one or more new rows in it.The [...]]]></description>
			<content:encoded><![CDATA[<p><img class="size-full wp-image-62038234 alignright" style="margin: 0px; border:0" title="MySQL Logo" src="http://timk.co.za/wp-content/uploads/2010/02/mysql_logo.gif" alt="" width="250"  />From time to time, I need to compare MySQL database tables and see what data has been added to the one in the time since I mysqldump&#8217;d the first one.</p>
<p>For example: Let&#8217;s say I have table_a as my snapshot&#8217;d table, and table_b as my newer table which has one or more new rows in it.The query below will return all records that are in table_b, and not in table_a.</p>
<pre><code>SELECT table_b.* FROM table_b
LEFT JOIN table_a ON table_b.id = table_a.id
WHERE table_a.item_id IS NULL</code></pre>
<p>This idea can be extrapolated to comparing the tables of two different databases:</p>
<pre><code>SELECT database_b.sometable.* FROM database_b.sometable
LEFT JOIN database_a.sometable ON database_b.sometable.id = database_a.sometable.id
WHERE database_a.sometable.item_id IS NULL</code></pre>
<p>The you can take those results and use them to INSERT the missing records, should you want to do this.</p>
]]></content:encoded>
			<wfw:commentRss>http://timk.co.za/2010/02/01/comparing-two-mysql-tables/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting up LAMP within a small network</title>
		<link>http://timk.co.za/2008/08/28/setting-up-lamp-within-a-small-network/</link>
		<comments>http://timk.co.za/2008/08/28/setting-up-lamp-within-a-small-network/#comments</comments>
		<pubDate>Thu, 28 Aug 2008 19:56:00 +0000</pubDate>
		<dc:creator>Tim Keller</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[3306]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[c#]]></category>
		<category><![CDATA[dotnet]]></category>
		<category><![CDATA[dyndns]]></category>
		<category><![CDATA[lamp]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[port forwarding]]></category>
		<category><![CDATA[wamp]]></category>
		<category><![CDATA[xampp]]></category>

		<guid isPermaLink="false">http://tumble.timokeller.net/post/47789789</guid>
		<description><![CDATA[My friend Alain K is deploying the first version of his soon-to-be-released desktop application, WealthWorks. It is designed for Personal Financial Advisors and Investors that need to track client information, risk profiles, investments and returns. He has a MySQL backend with which the C# client application connects.
Due to the latency on South African DSL connections [...]]]></description>
			<content:encoded><![CDATA[<p>My friend <a href="http://twitter.com/alainkermis" target="_blank">Alain K</a> is deploying the first version of his soon-to-be-released desktop application, <em>WealthWorks</em>. It is designed for Personal Financial Advisors and Investors that need to track client information, risk profiles, investments and returns. He has a MySQL backend with which the C# client application connects.</p>
<p>Due to the latency on South African DSL connections and the fact that the application is quite chatty, he is installing database servers within company intranets. This tutorial goes through the basics of making this work on a network where there are no static public IP Addresses available.</p>
<p><strong>Decisions</strong></p>
<p>Start with a piece of paper. Draw the network including any cables, routers, computers or switches that you think are important. This will give you a broad understanding of where your server fits into the picture.</p>
<p>The computers on the network will access the server you are setting up via its  <a href="http://en.wikipedia.org/wiki/IP_address" target="_blank">IP Address</a>. Ask the network administrator for an open address which you can use.</p>
<p>Configure the computer to use this address as a Static IP.</p>
<p>Tutorial: Setting up a Static IP on Windows (<a href="http://portforward.com/networking/static-xp.htm" target="_blank">Read</a>)<br />
Tutorial: Setting a Static IP on OSX (<a href="http://www.answers.vt.edu/ask4help/connection/vtkb1867.htm" target="_blank">Read</a>)</p>
<p><strong>MySQL Installation</strong></p>
<p>Start by installing MySQL. If all you want is the database server then head over to the <a href="http://dev.mysql.com/downloads/mysql/5.0.html#downloads" target="_blank">download page</a> on MySQL.com and grab it. If you need a full Apache+MySQL+PHP stack then take a look at <a href="http://www.wampserver.com/en/" target="_blank">WampServer</a> (Windows only) or <a href="http://www.apachefriends.org/en/xampp.html" target="_blank">XAMPP</a> (MacOSX, Windows, Linux, or Solaris). Both packages include very cool GUIs for installing and controlling the server.</p>
<p><strong>MySQL Management</strong></p>
<p>You’ll no doubt want to change the root user password and upload your database scheme to your newly installed server. I personally use Navicat &#8211; a great GUI for MySQL which comes in both a <a href="http://mysql.navicat.com/download.html" target="_blank">paid and free version</a>. Give it the IP address you chose earlier, and the username and password of ‘root’ and blank (nothing, empty string, etc) respectively. In no time at all you’ll be browsing your database.</p>
<p>At this stage, all the other computers on the local network should be able to reach MySQL on the IP address you specified (remember, it serves connections on Port 3306).</p>
<p><strong>Accessing it from the outside<br />
</strong></p>
<p>The next step is to make your database accessible from outside of the local network. If you’re a consultant working from home or a different office, you’ll undoubtedly want this sort of access. Similarly, you may want clients to be able to connect in via the internet.</p>
<p>You need to tell your router to accept all incoming mysql traffic and push it to that server. We call this Port Forwarding. We are going to forward all traffic (on mysql port 3306) to our mysql server on our local network (also port 3306).</p>
<p>Follow the instructions on <a href="http://www.portforward.com/english/applications/port_forwarding/SSH/SSHindex.htm" target="_blank">PortForward.com</a> to configure your router.You want to forward all incoming traffic on port 3306 to 10.x.x.x (or 192.x.x.x) on port 3306.</p>
<p>Likewise, if you’ve got an Apache, MySQL, PHP setup on the server, you’ll want to access the website/webapplication by going to a URL from a web browser. The trick is to sign-up for a free DynamicDNS account at <a href="http://www.dyndns.com" target="_blank"></a><a href="http://www.dyndns.com">www.dyndns.com</a> and add that to your router’s configuration.</p>
<p>I trust this helps! Suggestions and thoughts, please <img src='http://timk.co.za/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://timk.co.za/2008/08/28/setting-up-lamp-within-a-small-network/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP+MySQL from the Mac OSX Terminal</title>
		<link>http://timk.co.za/2008/07/13/phpmysql-from-the-mac-osx-terminal/</link>
		<comments>http://timk.co.za/2008/07/13/phpmysql-from-the-mac-osx-terminal/#comments</comments>
		<pubDate>Sun, 13 Jul 2008 10:24:00 +0000</pubDate>
		<dc:creator>Tim Keller</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[BSD]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[OSX]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[Sockets]]></category>
		<category><![CDATA[xampp]]></category>

		<guid isPermaLink="false">http://tumble.timokeller.net/post/42082031</guid>
		<description><![CDATA[I had to write a CLI PHP script today as part of the job-parser for the SMS module in ChirpSchool. The parser executes every 5 minutes as a cron-job and dispatches waiting messages in the Message Queue.
I ran into a small problem in that the Command-Line-Interface PHP binary was different to the one running on [...]]]></description>
			<content:encoded><![CDATA[<p>I had to write a CLI PHP script today as part of the job-parser for the SMS module in ChirpSchool. The parser executes every 5 minutes as a cron-job and dispatches waiting messages in the Message Queue.</p>
<p>I ran into a small problem in that the Command-Line-Interface PHP binary was different to the one running on my Apache+Mysql+PHP stack so the CLI PHP didn&#8217;t know which MySQL socket to attach to:</p>
<blockquote>
<p>Warning: mysqli_connect(): (HY000/2002): Can&#8217;t connect to local MySQL server through socket &#8216;/var/mysql/mysql.sock&#8217;</p>
</blockquote>
<p>The solution is simple. I am using Mac OSX 10.5.4 Leopard and XAMPP.</p>
<ol>
<li>Find out which PHP you are using from the terminal by typing &#8216;whereis php&#8217;. It is no doubt /usr/bin/php. <br/>
</li>
<li>Create a php.ini in /etc. Type &#8216;sudo cp /etc/php.ini.default /etc/php.ini</li>
<li>Then open this new file in something&#8230; I did a &#8216;sudo nano /etc/php.ini&#8217;.</li>
<li>Edit the mysqli.default_socket parameter (or mysql if you aren&#8217;t using the new improved driver) to point to the MySQL socket Apache is using. Mine was at /Applications/xampp/xamppfiles/var/mysql/mysql.sock (your&#8217;s may be at  /tmp/mysql.sock)</li>
<li>Be sure to save this new php.ini. Remember, /etc is protected so you won&#8217;t be able to save the file unless you have sudo&#8217;d yourself admin rights.<br/>
</li>
<li>Commenter<b> ferzkopp</b> kindly reminds us that an Apache restart may be neccesary to get this activated. Thanks for the Tip! </li>
</ol>
<p>Hope this helps!</p>
]]></content:encoded>
			<wfw:commentRss>http://timk.co.za/2008/07/13/phpmysql-from-the-mac-osx-terminal/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
