db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Josh Holtzman <j...@joshholtzman.com>
Subject Re: How to delete all rows using doDelete?
Date Wed, 28 Jan 2004 18:40:59 GMT
Try using org.apache.torque.util.BasePeer.deleteAll()

Cheers,
Josh

Steffen Mueller wrote:

> Hi Jiaqi,
>
> I am working with the latest version of Torque, version 3.1 as of Sept 
> 1, 2003.
>
> Will this problem be fixed in the next release?  Are there other 
> solutions to this problem?
>
> Regards,
> Steffen
>
> At 03:27 AM 1/28/2004, you wrote:
>
>> Hi Steffen,
>>
>> I'm not sure which version of torque are you working on. I've met this
>> problem before, but now it's ok.
>> Anyway, what did I do is add a condition which is always true into 
>> criteria.
>> For example, AbcPeer.doDelete(new Criteria().and(AbcPeer.ABC_ID, new
>> Integer(-1), Criteria.GREATER_THAN)));
>> Good luck
>>
>>
>> Regards
>> Jiaqi Guo
>>
>> email: g-cyclops@users.sourceforge.net
>> site: http://cyclops-group.sourceforge.net
>> -----Original Message-----
>> From: Steffen Mueller [mailto:torque@mueller.ca]
>> Sent: Tuesday, January 27, 2004 11:02 AM
>> To: torque-user@db.apache.org
>> Subject: How to delete all rows using doDelete?
>>
>> I tried to truncate (or: delete all rows) in a table using Torque:
>>
>> CoachingPeer.doDelete(new Criteria());
>>
>> This doesn't work (no error message comes up, it just does nothing), and
>> the documentation confirms that this shouldn't work.
>>
>> Does anyone know the correct deDelete call to delete all rows?
>>
>> Thanks,
>> Steffen
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
>> For additional commands, e-mail: torque-user-help@db.apache.org
>>
>>
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
>> For additional commands, e-mail: torque-user-help@db.apache.org
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
> For additional commands, e-mail: torque-user-help@db.apache.org
>

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


Mime
View raw message