With all due respect, this vitiates much of the point of using Torque. A
major reason for my using Torque is that I thereby do *not* have to hand
craft SQL: it is a tedious and error prone process.
Hand-crafted SQL means that code maitnenance is much more difficult. If I
change the schema, with pure Torque my code will probably fail to compile.
If I have written SQL by hand the code will still compile and I will not
discover any errors until run-time.
|---------+--------------------------------->
| | "Vitzethum, Daniel" |
| | <[EMAIL PROTECTED]|
| | tronik.com> |
| | |
| | |
| | 14-Mar-2005 14:50 |
| | Please respond to |
| | "Apache Torque Users |
| | List" |
| | <[EMAIL PROTECTED]|
| | .org> |
| | |
|---------+--------------------------------->
>-------------------------------------------------------------------------------------------------------------------------|
|
|
|
|
|
|
| To: "Apache Torque Users List" <[email protected]>
|
|
|
| cc:
|
| Subject: AW: inefficient doDelete
|
>-------------------------------------------------------------------------------------------------------------------------|
Hello Paul,
> How are people handling this?
as already mentioned by someone else (Thomas?), I suppose you
could/should
delegate it to the database with a custom sql, e.g.
BasePeer.executeStatement("DELETE FROM " + FooPeer.TABLE_NAME + "
WHERE " + FooPeer.A_COLUMN + "=1");
That wouldn't load all records and use the performance of the DB for
large amounts of data.
HTH,
Daniel
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]