Dr. Dobb's Journal May 1997
public class DatabaseException extends Exception
{
public DatabaseException()
{
super();
}
public DatabaseException(String error)
{ // you can make your exception be a gui dialog
// or a command line printout
// this invokes the system message
// then prints an error in the java console
super(); System.out.println("Database error:" + error); }
}