[prev in list] [next in list] [prev in thread] [next in thread] 

List:       turbine-torque-user
Subject:    Re: retrieveByPK
From:       T E Schmitz <mailreg () numerixtechnology ! de>
Date:       2005-09-06 7:23:49
Message-ID: 431D4405.8050600 () numerixtechnology ! de
[Download RAW message or body]

barak wrote:
> Hi all,
>  
> Is there a way to configure torque so the method "retrieveByPK" in the
> peers will return null instead of an exception if no row matched the
> primary key?

Why don't you write your own retrieveByPK method in the class that 
extends the peer class?
Unfortunately, the peer class methods are all static, so you are not 
really overriding the base class' method but masking it.
Call the perr base class' method, catch the exceptions and return null.

> If it can be done, will this also effect other types of exceptions?



-- 


Regards/Gruß,

Tarlika Elisabeth Schmitz

---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic