You are viewing a plain text version of this content. The canonical link for it is here.
Posted to torque-user@db.apache.org by Ashley Hayes <as...@macalla.com> on 2003/10/17 12:14:56 UTC
why does Torque select all the data of an object prior to a sav
e ( update )
Hi,
I was looking at the sql statements made by my torque application. I
noticed that if you retrieve an object from storage, SELECT .... FROM ...
WHERE ...
then update an attribute and call save , the all the data is retrieved
again and then the update statement executed
e.g. SELECT * FROM ... WHERE ID=1280
UPDATE ... SET DATETIME = ?, STATUS_ID = ? WHERE ID = ?
The torque code that is causing this in BasePeer:
public static void doUpdate(
Criteria selectCriteria,
Criteria updateValues,
Connection con)
throws TorqueException
{
....
}
Is this behaviour by torque design or the only way torque can update records
via the village library?
thanks
A
---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org
RE: why does Torque select all the data of an object prior to a save ( update )
Posted by Ramesh Sabeti <rs...@reazon.com>.
Ashley,
Did you find an answer to your question, or find a solution? I'm
running into the same problem. It's crashing the Oracle server after a
few days of use.
Ramesh.
> -----Original Message-----
> From: Ashley Hayes [mailto:ashley.hayes@macalla.com]
> Sent: Friday, October 17, 2003 3:15 AM
> To: Torque-User (E-mail)
> Subject: why does Torque select all the data of an object prior to a
save
> ( update )
>
> Hi,
> I was looking at the sql statements made by my torque
application. I
> noticed that if you retrieve an object from storage, SELECT .... FROM
...
> WHERE ...
>
> then update an attribute and call save , the all the data is
retrieved
> again and then the update statement executed
>
> e.g. SELECT * FROM ... WHERE ID=1280
> UPDATE ... SET DATETIME = ?, STATUS_ID = ? WHERE ID = ?
>
> The torque code that is causing this in BasePeer:
> public static void doUpdate(
> Criteria selectCriteria,
> Criteria updateValues,
> Connection con)
> throws TorqueException
> {
> ....
> }
>
> Is this behaviour by torque design or the only way torque can update
> records
> via the village library?
> thanks
> A
>
> ---------------------------------------------------------------------
> 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