By David Fekke
January 17th, 2011
One of the mistakes I have seen developers make is not using bulk transaformations in SQL. It does not matter if you use MS SQL Server, Oracle, DB2 or MySQL, all of the RDBMS's provide developers a way to perform bulk transformations of data.
One of the powerful things about SQL is that you can update or insert thousands or millions of records with one SQl Statement. Here is a simple example. Lets say I have a thousand records in a table that have a bit column to determine if a record is active. I can set every record of that table to inactive with two lines of SQL.
SET Active = 0;
SET active = 0
WHERE State = 'CA';
SELECT fName, lName, Address1, City, StateProvince, ZipCode