Monday, October 27, 2003

ColdFusion Code Review Tool now $50

I lowered the price on our ColdFusion CodeReview tool today to $50 (from $200 per developer)! The tool can find problems in your code (such as lack of CFQUERYPARAM, or SELECT *), and you can also easily define your own rules in just a few lines of code.

Even if your not interested in the tool, don't forget that the code review rules are posted on our web site - free for everyone to use.

Thursday, October 23, 2003

Top 3 differences between PostgreSQL and MS SQL

I recently switched a database server from MS SQL Server over to postgresql. Here's the top three differences in SQL:

  • NO TOP, so SELECT TOP 10 * FROM table, becomes SELECT * FROM table LIMIT 10 you can also use the maxrows attribute of CFQUERY to do this, if you want cross db code (which is good). MySQL also uses the LIMIT sytax, but Oracle uses yet another syntax
  • LIKE statements are case sensitive in postgresql, they can be made case insensitive like this: SELECT * FROM table WHERE LOWER(column) LIKE '%#LCase(var)#%'
  • The plus operator cannot be used for concatination so SELECT firstname + ' ' + lastname AS fullname becomes SELECT firstname || ' ' || lastname AS fullname this way works on both servers.

Amazon's Search inside the book

Amazon is now offering full text book searching, they call "Search inside the book".
Starting today you can find books at based on every word inside them, not just the author, or title keywords. Search inside the book -- the name of this new feature -- searches the complete inside text of more than 120,000 books -- all 33 million pages...

And while we are on the subject of Amazon, check out this Shopping web site for findind deals on There is also a shopping blog that goes with it.

Wednesday, October 15, 2003

ColdFusion Training

I recently learned of two resources for developers looking to improve their ColdFusion skills:

Webucator ( - Webucator provides customized onsite ColdFusion training an At-Your-Own-Pace online ColdFusion courses.

LearnByHeart ( - LearnByHeart is a Web-based service that helps developers pass Macromedia certification exams by practicing on sample exams.

What Every Software Developer Must Know About Unicode and Character Sets

Joel Spolsky has a good article titled: The Absolute Minimum Every Software Developer Absolutely, Positively Must Know About Unicode and Character Sets (No Excuses!).

Monday, October 13, 2003

HackNotes for Linux and Unix

There is a review of HackNotes Linux and Unix Security portable reference on slashdot. Looks like a pretty good book, I know that the CodeNotes series are good concise references. They are typically under 250 pages (this one is 224 pages) which is nice when many books web developers are buying are thousands of pages.

I have CodeNotes for J2EE, CodeNotes for Java, CodeNotes for ASP.NET, and CodeNotes for XML. I have found all of them to be pretty good, the J2EE one has been most useful to me, and the Java one is good, but I know Java pretty well so I don't have much need for it. The books are also dirt cheap, so you can't go wrong.

Wednesday, October 01, 2003

Using Ant to test Concurrency

Apache Ant is an awesome tool for creating batch builds, and doing all sorts of automated tasks. It was designed to replace make files, but you can use it for lots of things, as my example will show. Ant uses an XML language, with tasks (tags) to compile java classes, run java classes, manipulate the file system, create zip or tar.gz files, run SQL statements, XSL, FTP, etc. It also has an extensible API so there are tasks to do pretty much anything you would like to automate. We use ant at CFDEV to package our products into zip files, encrypt CFM templates, create multiple versions, and even upload the distribution files to our server - all in one step!

To get started check out the Ant Manual

One Ant task that I have found useful recently for testing concurrency is that parallel task. It allows you to run several ant tasks within their own thread. I was using this to test some java code but you could also use it to test a web site.

Here's a code sample testing concurrent requests.

<?xml version='1.0'?>
<project name="Concurrent" default="test" basedir=".">
	<target name="test">
			<get src="" dest="1.html" />
			<get src="" dest="2.html" />
			<get src="" dest="3.html" />
			<get src="" dest="4.html" />
			<get src="" dest="5.html" />

Save the above contents in a file called build.xml and run the file by browsing the directory you saved it in with your shell, and typing ant (after installing ant ofcourse). You can add more concurrent threads just by adding more get tags.