Keep replication in mind when writing SQL code.

This is something I got "bitten" once, especially if you have a development server with its own database not replicated and production database is replicated. That slight difference is enough to cause production problems that may not be noticeable days after production release. As a wise man say:
When programming SQL statements, be mindful of replication.
Well, [...]

Posted on February 8th, 2009 under General SQL, Quick Tips • No Comments

Emulating nextval() function to get sequence in MySQL

There are times when auto increment is not sufficient. And there are times when what you need is actually a sequence. Unfortunately MySQL doesn’t have support for sequence. Having been working on PostgreSQL database as well, I found that it’s nextval() function is pretty nice. So in this article, I’d like to emulate (or implement) [...]

Posted on February 8th, 2009 under MySQL • 19 Comments

Layman’s understanding of Networking & UDP/TCP/IP

In this article, I’d like to explain, in layman terms, how computer networking works, in particular TCP/IP — the protocol that’s used on the internet. It will cover internet addressing, domain names, and ports. Hopefully by the end of reading this article, you’ll be able to understand better about how information transfers among computers. On [...]

Posted on February 4th, 2009 under Networking • 3 Comments

Customizing grep tool to exclude svn.

I mostly do programming by SSH-ing to development server. The code I’m working on are often managed by using SVN. There are many occasions when I need to search all source code to find a particular string. If you’ve worked on a source code that’s managed by SVN before, you’ll pretty soon notice that there [...]

Posted on February 4th, 2009 under General Unix, Quick Tips • No Comments

Analyzing data in Unix using PHP CLI.

There are times when I need to quickly gather some quick data in a simple tab based or space based delimited file, most often log files. Also, the files that I work on are often huge, well according to my standard at least … about 1GB. The data that I need is often simple statistics [...]

Posted on February 4th, 2009 under General Unix, PHP • No Comments

Page 6 of 10« First...«45678»...Last »