<?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>Databases and Life &#187; Uncategorized</title>
	<atom:link href="http://www.databasesandlife.com/category/uncategorized/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.databasesandlife.com</link>
	<description>Adrian Smith's blog</description>
	<lastBuildDate>Wed, 14 Dec 2011 10:13:11 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Self-employed again</title>
		<link>http://www.databasesandlife.com/2011-self-employed/</link>
		<comments>http://www.databasesandlife.com/2011-self-employed/#comments</comments>
		<pubDate>Wed, 30 Mar 2011 15:11:40 +0000</pubDate>
		<dc:creator>adrian</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.databasesandlife.com/?p=802</guid>
		<description><![CDATA[For various reasons I have decided to leave s IT Solutions. The company was good, I stand by everything I said in my previous blog posts about working for large companies. (1) I felt my position there was too junior. I was constantly having to justify the things I wanted to do in large meetings [...]]]></description>
			<content:encoded><![CDATA[<p>For various reasons I have decided to leave <a href="http://www.s-itsolutions.at/">s IT Solutions</a>. The company was good, I stand by everything I said in my previous blog posts about <a href="/s-it-solutions/">working for large companies</a>.</p>
<p><strong>(1) I felt my position there was too junior.</strong> I was constantly having to justify the things I wanted to do in large meetings with various &#8220;senior&#8221; people who&#8217;d been working there for 10 or more years. But these people were younger than me, and had been working at that company all their life, and simply didn&#8217;t have the variety of experience that I had. They felt things had to be done a certain way, but I had seen various ways including the way they were proposing, but they weren&#8217;t interested in listening to my input on the consequences of that way. Basically the reason for that was people didn&#8217;t want to dilute their power; I don&#8217;t hate them for this, I just don&#8217;t need to work there either.</p>
<p><strong>(2) Various things were far too complex. </strong>It took me about a month to learn how to deploy something on one particular environment (this <em>wasn&#8217;t </em>the live environment!) which involved asking a project manager for a release number (which involved justifying to him why the deployment was necessary, often he didn&#8217;t agree..), writing an email to dept X, they would forward that to dept Y, then there was some Windows tool with multiple tabs and multiple fields per tab, where you had to enter various magic data, plus there was something on the Windows tray you had to right-click and configure, then there was the web-based deployment tool and you had to know where to click in that.. Plus I didn&#8217;t have permission for any of these systems, I didn&#8217;t know that I needed to have asked in the past for permissions to these systems as I only discovered &#8220;just in time&#8221; that they existed at all. No documentation, nobody told me they existed as that would reduce their power that the bosses needed to go to them to get something done.</p>
<p>Anyway, I was told at least once, &#8220;well, you might not like it, but you&#8217;ll have to get used to it. That&#8217;s the way your life is now!!&#8221;. Wrong ;-)</p>
<p>For the next months I have the following things lined up:</p>
<p><strong>(1) Implementation of a <a href="http://wicket.apache.org/">Java Wicket</a> based system of analyzing mobile phone usage data.</strong> Usage data is uploaded via CSV files, I parse them and put them into a database, then the main screen involves a set of reports, defined over a configuration file, with snippets of &#8220;where&#8221; clauses in them. The user may select further restrictions via drop-downs, these are added to the &#8220;where&#8221; clause. The &#8220;select&#8221; against the DB is performed and an XML is created of the results. XSLT created by <a href="http://www.altova.com/stylevision.html">Altova Stylevision</a>, which the customer has created and checked into my SVN, is then performed on the XML to produce PDF, RTF or HTML reports. I don&#8217;t need to change any code to change the layout of the report, it&#8217;s all in the XSLT file. To give the user a nice interface for managing the CSV files Windows Explorer and TortoiseSVN is used, I read the reports from SVN and insert the data programmatically via <a href="http://svnkit.com/">svnkit</a> which is nice and easy to use, and I keep the database and configuration in sync like <a href="/atomic-operations-over-filesystem-and-database/">this</a>. <a href="http://www.onestopconcept.com/">Onestop Concept</a> provided analysis of the requirements, and I did all the software architecture and programming. Deployed at <a href="http://www.nessus.at/">Nessus</a>. All in all, a nice project!</p>
<p><strong>(2) Further implementation on <a href="http://www.onestopconcept.com/offer-ready">Offer Ready</a></strong> for Onestop Concept (Martin Schmidt) which involves using some cool algorithms to determine which mobile phone tariff (incl. packs) is the best option given a set of usage data. Written in Java and C. (<a href="/java-method-64k-limit/">Not written only in Java!</a>)</p>
<p><strong>(3) Working for <a href="http://www.firstload.de/">firstload</a></strong> (hopefully!), a platform where you can download binary files acquired from Usenet. I will be working on their e-commerce software, for example the invoice-generation software, introducing tax rules, extending/re-writing the subscriptions logic, modernizing the software, and so on. PHP and MySQL. This is a domain I&#8217;ve worked in a few times before, I did the e-commerce software for Uboot&#8217;s SMS functionality, I wrote the Subscriptions system for <a href="http://www.easyname.eu/">easyname</a> for <a href="http://www.nessus.at/">Nessus</a>, was hired to write a pay-out and tax logic module for TheContentMarket then <a href="http://www.fatfoogoo.com/">FatFoogoo</a>, and so on.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.databasesandlife.com/2011-self-employed/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Teamwork training in Neusiedl</title>
		<link>http://www.databasesandlife.com/coverdale/</link>
		<comments>http://www.databasesandlife.com/coverdale/#comments</comments>
		<pubDate>Fri, 26 Nov 2010 15:54:54 +0000</pubDate>
		<dc:creator>adrian</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.databasesandlife.com/?p=758</guid>
		<description><![CDATA[I&#8217;ve just got back from a 4-day course on working in teams (&#8220;Erfolgreich Zusammenarbeit im Team&#8221; by Coverdale for my employer s IT Solutions). First conclusion -&#62; Top food at Hotel Wende in Neusiedl am See. I am so tired now, it was much more tiring than I had imagined it would be. Lots of &#8220;exercises&#8221; which really [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve just got back from a 4-day course on working in teams (&#8220;<a href="http://www.coverdale.at/cmbt/webat.nsf/htmlindex/CD242A0DA8242BD6C125764F003F581E.htm">Erfolgreich Zusammenarbeit im Team</a>&#8221; by <a href="http://www.coverdale.at/">Coverdale</a> for my employer <a href="http://www.s-itsolutions.at/">s IT Solutions</a>).</p>
<p>First conclusion -&gt; Top food at <a href="http://www.hotel-wende.at/">Hotel Wende</a> in Neusiedl am See.</p>
<p>I am so tired now, it was much more tiring than I had imagined it would be. Lots of &#8220;exercises&#8221; which really required a lot of concentration, especially if one was to learn the maximum possible from them. I must admit I went into it not expecting much (it was a mandatory course) but I tried my best anyway and did actually learn more than I thought i would (i.e. more than zero). (It did start a bit like <a href="http://en.wikipedia.org/wiki/Episode_Four_(The_Office,_Series_One)">S01E04 of the Office UK</a>, I must admit..)</p>
<p>So here are my learnings, in no particular order -  (as much for my benefit in the future as anything else)</p>
<ul>
<li><strong>Individual creativity. </strong>If you ask everyone in the room for ideas, once the first person suggests an idea, everyone tends to discuss and build on that. If you ask everyone individually to write ideas down, in silence, then you have a much greater range of suggestions.</li>
<li><strong>Need for moderation in meetings. </strong>In the exercises, it became clear that without a moderator / leader, the subject would wander randomly, and away from what should be discussed. This is rather obvious, but seems to contradict &#8220;scrum&#8221; (or at least the way it&#8217;s done where I work), where the belief is that if you put a range of people together, they&#8217;ll &#8220;work it out&#8221; and magically great ideas will be formed (instead this leads to &#8220;design by committee&#8221;).</li>
<li><strong>In meetings, write on a whiteboard not on paper. </strong>When dealing with a common idea, I am the one who tends to write the things down. Although it sounds obvious, I had never really noticed that nobody else can see what I&#8217;m writing it down. Writing the same thing on a white-board means everyone can see what&#8217;s going on and can comment on it.</li>
<li><strong>Dealing with blocking people. </strong>When dealing with people who are excessively negative and blocking in meeting, where no one can suggest anything without being shot down by the &#8220;expert&#8221;, it was suggested to try and actively split the process into two parts (1) Creation and collection of ideas, (2) Feedback/Risks to those ideas. I shall give this a try.</li>
<li><strong>If a new team member joins your team</strong>, try and treat them as equal to the existing team members as soon as possible. I certainly welcome when this is done. (I caught myself saying I was &#8220;new&#8221; the other day, although I&#8217;ve been at the company for 9 months. I wondered why that was. I realize now it&#8217;s because the people who&#8217;ve been there longer guard their role, don&#8217;t treat new people as equals, therefore I still feel new.)</li>
<li><strong>Write not only the answers but also the question</strong> on the white-board &#8211; When writing answers to a question on the white-board, if you don&#8217;t include the question (i.e. just ask it verbally at the start of the meeting) people forgets that the answers increasingly don&#8217;t fit to the question as the discussion progresses and the topic wanders.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.databasesandlife.com/coverdale/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>1k reputation on stackoverflow.com</title>
		<link>http://www.databasesandlife.com/1k-reputation-on-stackoverflow-com/</link>
		<comments>http://www.databasesandlife.com/1k-reputation-on-stackoverflow-com/#comments</comments>
		<pubDate>Fri, 05 Nov 2010 14:18:01 +0000</pubDate>
		<dc:creator>adrian</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.databasesandlife.com/?p=703</guid>
		<description><![CDATA[A few weeks ago I got really into stackoverflow.com, the question/answer site for programming: But now I&#8217;ve got a bit bored of it. If you want to achieve reputation, it seems you have to take the following things into account: People will only vote up your answers who are able to see that your answer [...]]]></description>
			<content:encoded><![CDATA[<p>A few weeks ago I got really into <a href="http://stackoverflow.com/">stackoverflow.com</a>, the question/answer site for programming:</p>
<p style="text-align: center; margin-bottom: 20px;"><a href="http://stackoverflow.com/users/220627/adrian-smith"><br />
<img src="http://stackoverflow.com/users/flair/220627.png" alt="Adrian Smith on stackoverflow.com" width="208" height="58" /><br />
</a></p>
<p>But now I&#8217;ve got a bit bored of it. If you want to achieve reputation, it seems you have to take the following things into account:</p>
<ul>
<li>People will only vote up your answers who are able to see that your answer is correct; therefore common topics or easy topics (such as simple SQL questions) will get more votes and therefore reputation points than something which requires more detailed knowledge such as Oracle optimization tips or Lucene full-text search indexing strategies. (Example of a <a href="http://stackoverflow.com/questions/3996243/will-this-regex-patterns-catch-all-the-needed-sql-injections/3996279#3996279">popular answer</a>, example of <a href="http://stackoverflow.com/questions/3658141/is-it-possible-to-re-generate-lucene-index-in-background/3942685#3942685">non-popular answer</a>)</li>
<li>Obviously once a question has been correctly answered, there&#8217;s no point in answering it again. Therefore people tend to surf the newest questions, looking for things to answer. Therefore if you answer a really old question, even if it&#8217;s still valid and hasn&#8217;t been answered, nobody will see it and vote up your answer and you won&#8217;t get points.</li>
<li>People looking at a question, if there are 3 of 4 answers, they will vote up one of them if they are correct. If yours isn&#8217;t there yet, you don&#8217;t get voted up (yet). Therefore you have to answer quickly. Answering quickly is probably the exact opposite of answering in a reflected and considered way, with a lot of detail, etc.</li>
</ul>
<p>So basically you have the situation that, in order to gain points, you have to keep on refreshing the &#8220;newest questions&#8221; page, find a really easy question which anyone could answer, and then answer it in a really non-detailed way.</p>
<p>But still, for a week or so, I was obsessed with my status. So it&#8217;s been definitely a good learning experience for me, that &#8220;game mechanics&#8221; with arbitrary rewards (which don&#8217;t cost the site owner anything) can really get your users to get obsessed with whatever you want them to do and make them do free work for you (in this case, build up a set of questions and answers on a website, which does have value to the site owner).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.databasesandlife.com/1k-reputation-on-stackoverflow-com/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>XSS attack via unchecked image uploads</title>
		<link>http://www.databasesandlife.com/xss-attack-images/</link>
		<comments>http://www.databasesandlife.com/xss-attack-images/#comments</comments>
		<pubDate>Tue, 17 Aug 2010 11:45:20 +0000</pubDate>
		<dc:creator>adrian</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.databasesandlife.com/?p=651</guid>
		<description><![CDATA[If you allow users of your website to upload data (e.g. images), and you display this data to other users, you need to open the file on the server to examine it and check that it really is what it should be (e.g. an image). Most website software will need to examine the image anyway, [...]]]></description>
			<content:encoded><![CDATA[<p><strong>If you allow users of your website to upload data (e.g. images), and you display this data to other users, you need to open the file on the server to examine it and check that it really is what it should be (e.g. an image).</strong></p>
<p>Most website software will need to examine the image anyway, to extract thumbnails, determine width/height, etc. In which case, this security comes for free. But I&#8217;ve seen software which doesn&#8217;t have any such needs, and thus server-side examination is not done.</p>
<p>The reason is:</p>
<ul>
<li>An uploading user (attacker) may upload a file such as &#8220;xxx.jpg&#8221; whose contents are in fact HTML/Javascript rather than an image</li>
<li>The web server may serve this file with the extension in the URL and the Content-Type: image/jpeg, however…</li>
<li>Internet Explorer may under some circumstances ignore these two pieces of information, instead preferring to look at the bytes of the file, and work out what type of content the file contains</li>
<li>Even if the image looks right in the &lt;img&gt; tag, if the viewing user right-clicks and views the image in its own window, then the data will be interpreted as HTML/Javascript</li>
<li>This gives the file the capability to read the viewing user&#8217;s cookies, look into forms in other windows, etc., as the HTML/Javascript appears to have been served by the site the viewing user is viewing.</li>
<li>Through having e.g. &lt;img&gt; tags (not affected by single-source policy) the file can send e.g. GET requests to an external site and transport this cookie and form information.</li>
<li>Thus the attacker&#8217;s external site now has cookie/form information, and the attacker can use this to impersonate the user at the site.</li>
</ul>
<p>I was unaware of this before <a href="http://twitter.com/ch2500">@ch2500</a> brought this my attention, thanks! <a href="http://www.h-online.com/security/features/Risky-MIME-sniffing-in-Internet-Explorer-746229.html">More information</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.databasesandlife.com/xss-attack-images/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Letters</title>
		<link>http://www.databasesandlife.com/letters/</link>
		<comments>http://www.databasesandlife.com/letters/#comments</comments>
		<pubDate>Mon, 16 Aug 2010 08:19:03 +0000</pubDate>
		<dc:creator>adrian</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.databasesandlife.com/?p=586</guid>
		<description><![CDATA[The UNIX program &#8220;mail&#8221;, not the mail client one would use by choice under most circumstances. However today I have the pleasure of using a Solaris box which seems to be filled only with legacy tools like original &#8220;vi&#8221;, a &#8220;tail&#8221; where if you do &#8220;tail -f *&#8221; it only tails the first matching file [...]]]></description>
			<content:encoded><![CDATA[<p>The UNIX program &#8220;mail&#8221;, not the mail client one would use by choice under most circumstances. However today I have the pleasure of using a Solaris box which seems to be filled only with legacy tools like original &#8220;vi&#8221;, a &#8220;tail&#8221; where if you do &#8220;tail -f *&#8221; it only tails the first matching file and not all files.. but I digress.</p>
<pre>$ mail
mail: Too many letters, overflowing letters concatenated
</pre>
<p>I mean ignoring the error itself and the disrespect which it forces me to show this program, look at the wording.</p>
<p>The error involves the word &#8220;letters&#8221;, i.e. the program was written before the word &#8220;mail&#8221; was the standard word for internet mail.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.databasesandlife.com/letters/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Humans reading source is not a strategy to defeat viruses</title>
		<link>http://www.databasesandlife.com/humans-reading-source-is-not-a-strategy-to-defeat-viruses/</link>
		<comments>http://www.databasesandlife.com/humans-reading-source-is-not-a-strategy-to-defeat-viruses/#comments</comments>
		<pubDate>Thu, 12 Aug 2010 10:23:49 +0000</pubDate>
		<dc:creator>adrian</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.databasesandlife.com/?p=581</guid>
		<description><![CDATA[Apple&#8217;s policy of reviewing all apps is officially (amongst other reasons probably) to make sure apps don&#8217;t contain viruses etc. However here we clearly see that having humans look over source code of all apps does not catch all policy violations (violations include writing viruses, and include other things as in this case): http://www.mobilecrunch.com/2010/08/12/apple-pulls-camera-from-the-app-store-after-its-developers-reveal-a-contraband-feature/ If [...]]]></description>
			<content:encoded><![CDATA[<p>Apple&#8217;s policy of reviewing all apps is officially (amongst other reasons probably) to make sure apps don&#8217;t contain viruses etc.</p>
<p>However here we clearly see that having humans look over source code of all apps does not catch all policy violations (violations include writing viruses, and include other things as in this case):<br />
<a href="http://www.mobilecrunch.com/2010/08/12/apple-pulls-camera-from-the-app-store-after-its-developers-reveal-a-contraband-feature/">http://www.mobilecrunch.com/2010/08/12/apple-pulls-camera-from-the-app-store-after-its-developers-reveal-a-contraband-feature/</a></p>
<p>If they can&#8217;t catch this policy violation, they won&#8217;t be able to catch all viruses either. (And they would need to catch all viruses to make it worth looking for viruses at all; catching all but one viruses is not sufficient. A single virus can do a lot of damage and infect widely.)</p>
<p>Apple not allowing one to just write and distribute code on their iPhone platform is an outrageous limitation of freedom. Presumably they have their reasons for doing so (e.g. so they make money on every commercial purchase of an application), but at least that reason they claim for doing it (protecting the public) is demonstrably not true.</p>
<p>(P.S. I&#8217;m not proposing a strategy which will defeat viruses; I&#8217;m just saying that Apple&#8217;s app store policy is not one.)</p>
<p>(P.P.S. Game console manufacturers have always had similar restrictions, those limitations of freedom are just as outrageous.)</p>
]]></content:encoded>
			<wfw:commentRss>http://www.databasesandlife.com/humans-reading-source-is-not-a-strategy-to-defeat-viruses/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Sudoku Solver</title>
		<link>http://www.databasesandlife.com/sudoku/</link>
		<comments>http://www.databasesandlife.com/sudoku/#comments</comments>
		<pubDate>Sat, 15 May 2010 13:45:16 +0000</pubDate>
		<dc:creator>adrian</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.databasesandlife.com/?p=515</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<style>
 div#sudokucontainer {  height:460px; text-align:center; }
 table.sudoku { empty-cells: show; border-collapse: collapse;  margin-left: auto; margin-right: auto; }
 table.sudoku div { font-size: 10pt }
 tr.sudokurow td { text-align:center; border: 1px solid #CCC; }
 tr.sudokurow td.leftcol { border-left: 3px solid black;  }
 tr.sudokurow td.rightcol { border-right: 3px solid black;  }
 tr.sudokurow.start td { border-top: 3px solid black;  }
 tr.sudokurow.end td { border-bottom: 3px solid black;  }
 tr.sudokurow td { width: 40px; height: 40px; }
 tr.sudokurow span.result { color: #AAA; }
 tr.sudokurow span.result,
 tr.sudokurow span.userentered,
 tr.sudokurow input.number { font-size: 19pt; font-family: helvetica }
 tr.sudokurow input.number { width: 20px; padding-left:2px; border:0; }
 table.sudoku td.statusrow { height:30px; text-align:center; vertical-align:top }
 table.sudoku td.statusrow .message { padding-left: 5px; }
 table.sudoku td.submitinfo { text-align:left  }
 table.sudoku td.submit { height:30px; text-align:right }
 table.sudoku div.spinner { text-right center ; }
 table.sudoku div.spinner img { margin-top:5px; margin-right: 10px; }
 td.statusrow .error,
 td.statusrow .success {
    padding-left: 7px;
    padding-right: 7px;
    display: inline;
    overflow: hidden;
 }
 td.statusrow .error {
    color: #800;
    background-color: #FCC;
    border: solid 1px red ;
 }
 td.statusrow .success {
    color: #080;
    background-color: #EFE;
    border: solid 1px green ;
 }
</style>
<table width="100%"">
<tr>
<td align="center">
<div id="sudokucontainer">
 </div>
</td>
</tr>
</table>
<p>The above is a Sudoku solver I wrote in Java a while back. Here it is running in the browser. The Java has been converted to in-browser Javascript by Google Web Toolkit.</p>
<p>Please feel free to type in the hardest Sudokus you can find anywhere, and let me know if it can solve them, I haven&#8217;t found any it can&#8217;t yet.</p>
<p>I assume the in-page Javascript will not work in RSS readers, email notifications, etc. If that&#8217;s the case, click here to get to the <a  href="http://www.databasesandlife.com/sudoku">original Sudoku solver page</a> on my blog.</p>
<p>The algorithm works by backtracking, i.e. simply going through all squares from top-left to bottom-right, and finding the set of &#8220;candidate numbers&#8221; for that square (i.e. which numbers are not already used on that row, column or 3&#215;3 block). The first candidate number is &#8220;applied&#8221; by placed it into the square, and the algorithm moves to the next square. If there is a square where the set of candidate numbers is empty (i.e. no number would work, given the candidates applied in previous squares) then the system returns to the previous square and tries the next candidate for that square. Once the system has gone &#8220;beyond&#8221; the bottom-right square, then the set of applied candidates consitutes a solution. However, backtracking continues, if the system reaches beyond the bottom-right square again, then the previously found solution<br />
was not unique, and the algorithm terminates. Once the system has backtracked back to the start, if a single solution was found then it is a &#8220;unique solution&#8221; (success case), otherwise if there are no solutions then the Sudoku is unsolvable.</p>
<p>By the way, Internet Explorer really isn&#8217;t that fast; I appreciate that is well-known to anyone who&#8217;s ever read Google Chrome marketing material! But the Sudoku <a href="http://z.about.com/d/puzzles/1/0/l/e/1/sudokux103.gif">here</a> takes 708ms to solve on IE8, 334ms on Firefox 3.6, about 100ms on Safari 4 and Opera 10, and 49ms on Chrome 4, on this 2.3GHz/core Intel Windows Vista computer.</p>
<p><strong>Update: </strong>Alas there were Sudokus which took too long for the original synchronous approach (i.e. user clicks, do calculation, update the screen with the results). So now, in the case the calculation takes too long, a &#8220;worker&#8221; is spawned, which does the calculation, and the spinner is displayed in that case.</p>
<p><a href="/blog-attachments/20100515-com.databasesandlife.sudoku.Sudoku/databasesandlife-sudoku-solver-source.zip">Download the source here</a>.<br />
<script language="javascript" src="/blog-attachments/20100515-com.databasesandlife.sudoku.Sudoku/com.databasesandlife.sudoku.Sudoku.nocache.js"></script></p>
]]></content:encoded>
			<wfw:commentRss>http://www.databasesandlife.com/sudoku/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>My mate came across the following HTML</title>
		<link>http://www.databasesandlife.com/a-few-html-option/</link>
		<comments>http://www.databasesandlife.com/a-few-html-option/#comments</comments>
		<pubDate>Fri, 30 Apr 2010 19:03:32 +0000</pubDate>
		<dc:creator>adrian</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.databasesandlife.com/?p=494</guid>
		<description><![CDATA[&#60;select class="selectTitle" id="C5" name="C5"&#62; &#60;option value=""&#62;--select--&#60;/option&#62; &#60;option value="1"&#62;Mr&#60;/option&#62; &#60;option value="2"&#62;Ms&#60;/option&#62; &#60;option value="3"&#62;Mrs&#60;/option&#62; &#60;option value="4"&#62;Miss&#60;/option&#62; &#60;option value="5"&#62;Doctor&#60;/option&#62; &#60;option value="6"&#62;Judge&#60;/option&#62; &#60;option value="7"&#62;Professor&#60;/option&#62; &#60;option value="8"&#62;Councillor&#60;/option&#62; &#60;option value="9"&#62;Madam&#60;/option&#62; &#60;option value="10"&#62;Mr &#38;amp; Mrs&#60;/option&#62; &#60;option value="11"&#62;Rev&#60;/option&#62; &#60;option value="12"&#62;Sir&#60;/option&#62; &#60;option value="13"&#62;Major&#60;/option&#62; &#60;option value="14"&#62;See Questions&#60;/option&#62; &#60;option value="15"&#62;Lord&#60;/option&#62; &#60;option value="16"&#62;Lady&#60;/option&#62; &#60;option value="17"&#62;Prince&#60;/option&#62; &#60;option value="18"&#62;Dr&#60;/option&#62; &#60;option value="19"&#62;Eng&#60;/option&#62; &#60;option value="20"&#62;Lt Col&#60;/option&#62; &#60;option value="21"&#62;AirComm&#60;/option&#62; &#60;option value="22"&#62;AirMarsh&#60;/option&#62; &#60;option [...]]]></description>
			<content:encoded><![CDATA[<pre>&lt;select class="selectTitle" id="C5" name="C5"&gt;
  &lt;option value=""&gt;--select--&lt;/option&gt;
  &lt;option value="1"&gt;Mr&lt;/option&gt;
  &lt;option value="2"&gt;Ms&lt;/option&gt;
  &lt;option value="3"&gt;Mrs&lt;/option&gt;
  &lt;option value="4"&gt;Miss&lt;/option&gt;
  &lt;option value="5"&gt;Doctor&lt;/option&gt;
  &lt;option value="6"&gt;Judge&lt;/option&gt;
  &lt;option value="7"&gt;Professor&lt;/option&gt;
  &lt;option value="8"&gt;Councillor&lt;/option&gt;
  &lt;option value="9"&gt;Madam&lt;/option&gt;
  &lt;option value="10"&gt;Mr &amp;amp; Mrs&lt;/option&gt;</pre>
<p><span id="more-494"></span></p>
<pre>  &lt;option value="11"&gt;Rev&lt;/option&gt;
  &lt;option value="12"&gt;Sir&lt;/option&gt;
  &lt;option value="13"&gt;Major&lt;/option&gt;
  &lt;option value="14"&gt;See Questions&lt;/option&gt;
  &lt;option value="15"&gt;Lord&lt;/option&gt;
  &lt;option value="16"&gt;Lady&lt;/option&gt;
  &lt;option value="17"&gt;Prince&lt;/option&gt;
  &lt;option value="18"&gt;Dr&lt;/option&gt;
  &lt;option value="19"&gt;Eng&lt;/option&gt;
  &lt;option value="20"&gt;Lt Col&lt;/option&gt;
  &lt;option value="21"&gt;AirComm&lt;/option&gt;
  &lt;option value="22"&gt;AirMarsh&lt;/option&gt;
  &lt;option value="23"&gt;Archbishop&lt;/option&gt;
  &lt;option value="24"&gt;Archdeacon&lt;/option&gt;
  &lt;option value="25"&gt;Baron&lt;/option&gt;
  &lt;option value="26"&gt;Baroness&lt;/option&gt;
  &lt;option value="27"&gt;Bishop&lt;/option&gt;
  &lt;option value="28"&gt;Bombadier&lt;/option&gt;
  &lt;option value="29"&gt;BrigGen&lt;/option&gt;
  &lt;option value="30"&gt;Brigadier&lt;/option&gt;
  &lt;option value="31"&gt;Brother&lt;/option&gt;
  &lt;option value="32"&gt;Cadet&lt;/option&gt;
  &lt;option value="33"&gt;Canon&lt;/option&gt;
  &lt;option value="34"&gt;Captain&lt;/option&gt;
  &lt;option value="35"&gt;Cardinal&lt;/option&gt;
  &lt;option value="36"&gt;Chancellor&lt;/option&gt;
  &lt;option value="37"&gt;Chief&lt;/option&gt;
  &lt;option value="38"&gt;ChiefJust&lt;/option&gt;
  &lt;option value="39"&gt;Colonel&lt;/option&gt;
  &lt;option value="40"&gt;ColSgt&lt;/option&gt;
  &lt;option value="41"&gt;Commander&lt;/option&gt;
  &lt;option value="42"&gt;Commodore&lt;/option&gt;
  &lt;option value="43"&gt;Constable&lt;/option&gt;
  &lt;option value="44"&gt;Corporal&lt;/option&gt;
  &lt;option value="45"&gt;Count&lt;/option&gt;
  &lt;option value="46"&gt;Countess&lt;/option&gt;
  &lt;option value="47"&gt;Dame&lt;/option&gt;
  &lt;option value="48"&gt;Deacon&lt;/option&gt;
  &lt;option value="49"&gt;Deaconess&lt;/option&gt;
  &lt;option value="50"&gt;Dowager&lt;/option&gt;
  &lt;option value="51"&gt;Duchess&lt;/option&gt;
  &lt;option value="52"&gt;Duke&lt;/option&gt;
  &lt;option value="53"&gt;Earl&lt;/option&gt;
  &lt;option value="54"&gt;Father&lt;/option&gt;
  &lt;option value="55"&gt;FldMarsh&lt;/option&gt;
  &lt;option value="56"&gt;FlightLt&lt;/option&gt;
  &lt;option value="57"&gt;FltSgt&lt;/option&gt;
  &lt;option value="58"&gt;FlOfficer&lt;/option&gt;
  &lt;option value="59"&gt;Frau&lt;/option&gt;
  &lt;option value="60"&gt;Fraulein&lt;/option&gt;
  &lt;option value="61"&gt;Fusilier&lt;/option&gt;
  &lt;option value="62"&gt;General&lt;/option&gt;
  &lt;option value="63"&gt;GrpCapt&lt;/option&gt;
  &lt;option value="64"&gt;Guardsman&lt;/option&gt;
  &lt;option value="65"&gt;Gunner&lt;/option&gt;
  &lt;option value="66"&gt;Herr&lt;/option&gt;
  &lt;option value="67"&gt;Inspector&lt;/option&gt;
  &lt;option value="68"&gt;JusticeCL&lt;/option&gt;
  &lt;option value="69"&gt;JusticeGN&lt;/option&gt;
  &lt;option value="71"&gt;LanceBmdr&lt;/option&gt;
  &lt;option value="72"&gt;LanceCorp&lt;/option&gt;
  &lt;option value="73"&gt;LieutCdr&lt;/option&gt;
  &lt;option value="74"&gt;LieutCol&lt;/option&gt;
  &lt;option value="75"&gt;LieutGen&lt;/option&gt;
  &lt;option value="76"&gt;Lieutenant&lt;/option&gt;
  &lt;option value="78"&gt;Madame&lt;/option&gt;
  &lt;option value="79"&gt;Mdmoiselle&lt;/option&gt;
  &lt;option value="80"&gt;MajorGen&lt;/option&gt;
  &lt;option value="81"&gt;Mrchioness&lt;/option&gt;
  &lt;option value="82"&gt;Marquess&lt;/option&gt;
  &lt;option value="83"&gt;Marquis&lt;/option&gt;
  &lt;option value="84"&gt;Marshal&lt;/option&gt;
  &lt;option value="85"&gt;Master&lt;/option&gt;
  &lt;option value="86"&gt;Matron&lt;/option&gt;
  &lt;option value="87"&gt;Mipshipman&lt;/option&gt;
  &lt;option value="89"&gt;Mistress&lt;/option&gt;
  &lt;option value="90"&gt;Monsieur&lt;/option&gt;
  &lt;option value="91"&gt;Monsignor&lt;/option&gt;
  &lt;option value="92"&gt;Mother&lt;/option&gt;
  &lt;option value="93"&gt;Nurse&lt;/option&gt;
  &lt;option value="94"&gt;Officer&lt;/option&gt;
  &lt;option value="95"&gt;Pastor&lt;/option&gt;
  &lt;option value="96"&gt;PC&lt;/option&gt;
  &lt;option value="97"&gt;PtyOffcr&lt;/option&gt;
  &lt;option value="98"&gt;PltOffcr&lt;/option&gt;
  &lt;option value="100"&gt;Princess&lt;/option&gt;
  &lt;option value="101"&gt;Private&lt;/option&gt;
  &lt;option value="102"&gt;Rabbi&lt;/option&gt;
  &lt;option value="103"&gt;RearAdmr&lt;/option&gt;
  &lt;option value="104"&gt;Rifleman&lt;/option&gt;
  &lt;option value="105"&gt;Sapper&lt;/option&gt;
  &lt;option value="106"&gt;Senor&lt;/option&gt;
  &lt;option value="107"&gt;Senora&lt;/option&gt;
  &lt;option value="108"&gt;Senorina&lt;/option&gt;
  &lt;option value="109"&gt;Sergeant&lt;/option&gt;
  &lt;option value="110"&gt;Signor&lt;/option&gt;
  &lt;option value="111"&gt;Signora&lt;/option&gt;
  &lt;option value="112"&gt;Signorina&lt;/option&gt;
  &lt;option value="113"&gt;Sister&lt;/option&gt;
  &lt;option value="114"&gt;SqnLeader&lt;/option&gt;
  &lt;option value="115"&gt;StaffSgt&lt;/option&gt;
  &lt;option value="117"&gt;SubLieut&lt;/option&gt;
  &lt;option value="118"&gt;Superintd&lt;/option&gt;
  &lt;option value="119"&gt;TheHon&lt;/option&gt;
  &lt;option value="120"&gt;TheRtHon&lt;/option&gt;
  &lt;option value="121"&gt;Trooper&lt;/option&gt;
  &lt;option value="122"&gt;Vicar&lt;/option&gt;
  &lt;option value="123"&gt;ViceAdmr&lt;/option&gt;
  &lt;option value="124"&gt;Viscount&lt;/option&gt;
  &lt;option value="125"&gt;Viscountss&lt;/option&gt;
  &lt;option value="126"&gt;Warrntoff&lt;/option&gt;
  &lt;option value="127"&gt;WingCmdr&lt;/option&gt;
  &lt;option value="128"&gt;WPC&lt;/option&gt;
  &lt;option value="129"&gt;Dom&lt;/option&gt;
  &lt;option value="130"&gt;Deputy&lt;/option&gt;
  &lt;option value="131"&gt;Rt. Honourable&lt;/option&gt;
  &lt;option value="132"&gt;Venerable&lt;/option&gt;
  &lt;option value="133"&gt;Sheikh&lt;/option&gt;
&lt;/select&gt;</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.databasesandlife.com/a-few-html-option/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>/etc/cron.daily scripts may not have dots in their name</title>
		<link>http://www.databasesandlife.com/etc-cron-daily-scripts-may-not-have-dots-in-their-name/</link>
		<comments>http://www.databasesandlife.com/etc-cron-daily-scripts-may-not-have-dots-in-their-name/#comments</comments>
		<pubDate>Sun, 18 Apr 2010 16:20:01 +0000</pubDate>
		<dc:creator>adrian</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.databasesandlife.com/?p=473</guid>
		<description><![CDATA[I just had the problem I&#8217;d placed a script into /etc/cron.daily on my Debian Lenny system but it wasn&#8217;t getting run (or at least it didn&#8217;t seem so). Two things I learned: (1) Execute the following to see which scripts would get run: run-parts --test /etc/cron.daily (2) In my case, the reason the script was [...]]]></description>
			<content:encoded><![CDATA[<p>I just had the problem I&#8217;d placed a script into /etc/cron.daily on my Debian Lenny system but it wasn&#8217;t getting run (or at least it didn&#8217;t seem so).</p>
<p>Two things I learned:</p>
<p>(1) Execute the following to see which scripts would get run:</p>
<pre>
run-parts --test /etc/cron.daily
</pre>
<p>(2) In my case, the reason the script was never executed was that I called it &#8220;xyz.sh&#8221; as it was a shell script; the dot in the filename was the problem. I removed the dot and now it runs.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.databasesandlife.com/etc-cron-daily-scripts-may-not-have-dots-in-their-name/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>&#8220;me&#8221; vs &#8220;you&#8221; in user-interface dialogs</title>
		<link>http://www.databasesandlife.com/me-vs-you-in-user-interface-dialogs/</link>
		<comments>http://www.databasesandlife.com/me-vs-you-in-user-interface-dialogs/#comments</comments>
		<pubDate>Mon, 15 Feb 2010 12:20:13 +0000</pubDate>
		<dc:creator>adrian</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.databasesandlife.com/?p=421</guid>
		<description><![CDATA[Computers, if they are addressing the user, should address the user as &#8220;you&#8221;, not as &#8220;me&#8221;. Computers need, from time to time, to address the user, for example &#8220;You have updated your setting successfully&#8221;. Some programs use the word &#8220;you&#8221; to address the user, some use the word &#8220;me&#8221; on the grounds that the user [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Computers, if they are addressing the user, should address the user as &#8220;you&#8221;, not as &#8220;me&#8221;.</strong></p>
<p>Computers need, from time to time, to address the user, for example &#8220;You have updated your setting successfully&#8221;.</p>
<p>Some programs use the word &#8220;you&#8221; to address the user, some use the word &#8220;me&#8221; on the grounds that the user is reading it, and to them, they are &#8220;me&#8221;.</p>
<p>However, using &#8220;me&#8221; to address someone is ridiculous! That&#8217;s as logical as a human using the word &#8220;I&#8221; or &#8220;me&#8221; to refer to the recipient of a piece of communication, &#8220;hey, do I fancy going to the pub?&#8221; on the grounds that, to the recipient, they are &#8220;I&#8221;.</p>
<p>&#8220;me&#8221; is the source of communication, &#8220;you&#8221; is the destination of communication; if a computer is communicating, the user is the recipient of the communication so should be called &#8220;you&#8221;.</p>
<p>Specifically Gmail is the main culprit for this in my life, it lists conversations between &#8220;me, Joe&#8221;; having &#8220;you, Joe&#8221; or &#8220;Adrian, Joe&#8221; would be much better! Gmail even, on the same screen that it lists conversations between &#8220;me&#8221; and other people, says &#8220;You are using 25% of your 7000MB&#8221;, so it&#8217;s not even consistent!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.databasesandlife.com/me-vs-you-in-user-interface-dialogs/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

