More MySQL quizzes
By Carsten | February 6, 2010
Not quite pop quiz format, but if you enjoyed the ones I published some time ago (almost 2 years ago now… how time flies), you’ll probably be interested to know that Read the rest of this entry »
Topics: MySQL, Pop Quiz | 3 Comments »
Skype: Remove the Cat (Webcam Avatar)
By Carsten | February 3, 2010
It took us a while to figure out where this was hidden, so I thought I’d post it here…
A member of my family has for a long time been battling with a “Webcam Avatar”, a stupid white cat that replaced his video feed in Skype. Apart from not knowing how it had entered his computer in the first place, whatever he did to reset his webcam settings, it would keep reappearing once Skype was restarted.
It turns out that the “Webcam Avatar” is not Skype-specific, but rather something that gets pre-installed along with all the other crap Dell puts on a laptop (or perhaps as part of a system upgrade).
So to remove it, you need to go the path of Control Panel-> Add/Remove programs -> Remove Live Cam Avatar. It might appear in more than one place
Topics: Uncategorized | No Comments »
There are Places You Just Don’t Want to Go…
By Carsten | November 7, 2009
on the web.
Overheard someone mentioning “Delhi Belly” in a conversation, and unable to figure from context what it was about, I headed to the otherwise very helpful Merriam-Webster dictionary.
Which, having defined the term, promptly and cheerfully suggests that you follow a link to “Visually explore traveler’s diarrhea”
Uhm. No thanks. I don’t think I will.
Topics: Uncategorized | No Comments »
And When the Delivery Truck Left, …
By Carsten | April 29, 2009
grmbl…
Topics: Uncategorized | No Comments »
Please stop wasting my time…
By Carsten | April 28, 2009
Another day, another application that insists on having to count every single object in the db/filesystem/whatever, just to show me a progress bar as it copies/updates/deletes something.
I. Don’t. Care.
Really. I just want you to get started on your task and get the job done.
If you insist on showing a progress bar, fine. But then get the counts you need in parallel with the operation you’ve been asked to perform. Perhaps you’ll find that the job you’ve been asked to do is completed before you finish counting.
User-friendliness my ****.
Getting the job done is user friendly. Wasting my time isn’t.
Topics: MySQL, php | 1 Comment »
Those were the days…
By Carsten | April 20, 2009
“We will be part of a larger company, but it will be called MySQL” Mickos said.
Sigh…
Topics: MySQL | 5 Comments »
My First Flash (nee Haxe) App
By Carsten | December 4, 2008
Kristian introduced me to Haxe, a cool scripting language that will let you easily write Flash, JavaScript and PHP applications that utilize the same set of libraries. Always keen to learn new stuff, I thought I’d try my hands at writing my nth iteration of the Game of Life, this time for Flash. (The Game of Life is my preferred “Hello World” equivalent; just slightly more complicated and good for learning how programming languages do basic UI stuff).
Writing the app turned out to be surprisingly trivial; from the time I downloaded Haxe until I was looking at the first iterations blink on the screen was just a few hours.
The main problem in using Haxe is the lack of structured library documentation; most of my “coding” time was spent Googling for information on which classes to use and how to use them.
Give it a whirl! If you need inspiration for starting patterns, try one of the two patterns below.
Topics: Haxe | 1 Comment »
Haxe: “Invalid Class name” during compilation
By Carsten | December 4, 2008
Did you use the right case? All Haxe class names must start with an uppercase letter. (this is documentet deep within this page)
Topics: Haxe | No Comments »
MySQL Pop Quiz #29
By Carsten | September 25, 2008
Yet another quiz inspired by Freenode#mysql IRC discussions. If you haven’t been around on the channel lately, you should have a peek. Lots of interesting discussions going on!
mysql> SELECT c1, c2 FROM t WHERE c2 LIKE 'a%'; +------+------+ | c1 | c2 | +------+------+ | a | abc | +------+------+
Is the following construct for the LIKE clause legal?
SELECT c1, c2 FROM t WHERE c2 LIKE CONCAT('a', '%');
And how about this one?
SELECT c1, c2 FROM t WHERE c2 LIKE CONCAT(c1, '%');
Bonus question: Suppose the table has many rows, several more columns and there’s an index on (c2, c1). Could that index be utilized when running the legal versions of the query — and if so, how?
Topics: MySQL, Pop Quiz | No Comments »
MySQL Pop Quiz #28
By Carsten | September 24, 2008
Don’t forget to send in your suggestions for new quizzes!
This quiz originated on FreeNode#mysql, where someone asked how to count the number of newline-separated “fields” in a TEXT column. For the purposes of the quiz, I’ve changed the idea slightly but you should be able to appreciate the usefulness of this method for any x-separated data that you have to deal with.
Given the following data…
mysql> SELECT * FROM t; +-----------+ | s | +-----------+ | aba | | abacad | | abacadaea | +-----------+
…create a query which counts the number of occurrences of the character ‘a’ in each line, e.g.
mysql> SELECT s, <something> AS count_a -> FROM t; +-----------+---------+ | s | count_a | +-----------+---------+ | aba | 2 | | abacad | 3 | | abacadaea | 5 | +-----------+---------+
Topics: MySQL, Pop Quiz | 3 Comments »

