Mar
10
2008
I am pleased to finally announce version 1.0 of DbFit. DbFit is an extension to FIT/FitNesse that makes test-driven database development easy. Version 1.0 (2008-03-10) is a major cleanup release, finally bringing proper documentation for the library as well. Grab it from SourceForge.
Continue Reading »
Feb
04
2008
I’m preparing for release 1.0 of DbFit — one of the new things will be support for In/Out parameters. A pre-release with this functionality is now available for testing.
- To use In/Out parameters, just define two columns for the same parameter. The one for OUT direction should have a question mark
- Order of parameters in the table is no longer important (it was in Java), so you should be able to put parameters in FitNesse pages in a different order then those in the database.
Here is an example:
|Execute procedure|MultiplyIO|
|factor|val|val?|
|10|5|50|
|2|8|16|
Introducing IN/OUT parameters required a huge change in the underlying parameter processing, please help by testing a pre-release and verifying that your old tests work with the new system as well.
SQL Server turned out to be especially tricky because there is no explicit IN/OUT flag on stored procedure parameters, and .NET driver does not expect all outputs to be simply declared as InputOutput, so there is an ugly workaround in the code to check whether an output parameter is also used for input. I do not expect any problems with this, but it’s best to double-check.
Get the binary builds for .NET and Java from SourceForge.
Dec
20
2007
I started compiling a list of Oracle SQL and PL/SQL bad practices, with the intention of producing a comprehensive catalogue of common and recurring programming mistakes, that can be used as a check-list for code reviews or given to junior developers. I have identified about 30 bad practices so far. For each bad practice, I provided a list of symptoms in the code, an explanation why it causes problems and a list of preferred solutions.
My goal with this list is primarily to start a discussion about similar recurring issues that other people have noticed. That discussion should lead to a more complete list which the community will then be able to use, hopefully, to learn something from the mistakes of others and to produce better code.
You can download the first version of the catalogue in PDF form from http://gojko.net/effective-oracle.
Nov
02
2007
One of the most interesting new features of Oracle 11 for me is the new function result caching mechanism. Until now, making sure that a PL/SQL function gets executed only as many times as necessary was a black art. The new caching system makes that quite easy - here is how it works. Continue Reading »