Python is a wonderful, easy-to-use programming/scripting language which can be implemented for virtually anything - scripting, web output, CGI, or full-blown applications. While it has not gained the recognition that Perl has among SysAdmins, it is fast catching up (in my opinion). Python, like Perl, has a large set of modules available for almost any task, is quick to prototype with, provides an interactive interpreter, and (in my opinion) has a more natural and easy syntax than Perl. Python is an interpreted language, and therefore does not require compilation.
Python can be used easily to handle mail. It is wonderful for creating a filter or handler program to use with ProcMail, and can perform analysis of mail headers.
PySQLite - Python SQLite class