SOUNDEX(), triggers, and stored procedures
MySQL provides a SOUNDEX() function, which returns the soundex of a given string. For details, refer to the manual, but to put it simply, it allows you to compare strings based on how they sound, hence letting you do proximity searches on your database. If you’re just querying for a word, it’s usage is pretty [...]
Extending procedure_analyse
My previous post explored a stored procedure that extended procedure_analyse with the intent of helping DBAs optimize table structure. Here’s an improved version. I’ve followed Arjen Lentz‘s suggestion and added support for the max_elements and max_memory parameters. I also added a new Indexed column to the output, which is an ENUM(‘No’,’Yes’,’Overindexed’). Yes and No are [...]
Coding Buddies
Coding Horror always has insightfull articles, and this one on code peer reviews is no exception. Why is it that writers, musicians and, well, any respected and professional artist or scientist gets his/her work reviewed before it’s published, but the same isn’t true in IT? My guess? Most programmers aren’t neither artists, nor scientists. They’re [...]
Generating random salts from bash
From the ‘just because it can be done’ column, here comes a handy shell script to generate random salts. So, without further ado, here it goes: #!/bin/bash [ $# -eq 0 ] && { echo “usage: salt <length>”>&2 exit } strings </dev/urandom | while read line; do echo $line | tr ‘\n\t ‘ $RANDOM:0:1 >> [...]
I love playing Monopoly
This is the latest speed test I run against Santiago de Chile, where a lonely database server is waiting for my queries. Well, it’s got a lot of waiting to do. This results are from a 2048 down /256 up Kb/s connection for which I pay U$S 52/monthly. Yeah, I feel your envy already. The [...]
Erlybird 0.17.0 released
Yep, I’m really late for this. However, I didn’t want to let it pass. I checked up on erlybird a couple of times before, but it was only available as a source project, and you needed a particular netbeans version in order to build the module. I’m as geek as it gets, but I’m also [...]
Intrusion detection at the application level, for PHP
Here’s phpids, an Intrusion Detection System for PHP. According to the site, it aims to counter XSS, SQL Injection, header injection, directory traversal, RFE/LFI, DoS and LDAP attacks, and unknown attack patterns, through it’s Centrifuge component. Installation is simple. Just download it, copy the lib directory to a directory in your project structure, or add [...]
Symbolics Lisp Machine
Wanna have your own Symbolics Lisp Machine? Here’s the info. I have enough room, I just live a few thousand miles too far, and have to deal with very picky Customs officials.
New release of MySQL Proxy GPL
MySQL Proxy has a new release, just three days ago, and if that wasn’t good enough, it’s now hosted on Launchpad, so it’s repository is on bazaar, which is great, and is what I’ve been using for my new projects. MySQL Proxy sits between clients and servers and offers many possibilities, load balancing being the [...]
Top 25 most dangerous programming errors
Most people make at least 8 or 9 of these in a new project, and this alone is a good reason to use a programming framework, unless you know what you’re doing. The problem is, sometimes, people who skip on frameworks, don’t know what they’re doing. Or, as the Tao of Programming says: There once [...]
