Re: Updating rows from a query

2004-11-02 Thread Stephen Rasku
On 02 Nov 2004 18:27:52 +0100, Harald Fuchs <[EMAIL PROTECTED]> wrote: > In article <[EMAIL PROTECTED]>, > > > >> Maybe you should explain what you're trying to achieve, not what you > >> think how to do it. > > > Sure. I am using MySQL to store packets for transmission. I want to > > send the

Re: Updating rows from a query

2004-11-02 Thread Harald Fuchs
In article <[EMAIL PROTECTED]>, Stephen Rasku <[EMAIL PROTECTED]> writes: >> I guess this is an oversimplification. Often you can use a single SQL set >> operation instead of a loop. Your example would probably be the same as >> >> UPDATE packet >> SET timestamp = now() >> WHERE timestamp < now

Re: Updating rows from a query

2004-11-02 Thread Stephen Rasku
On 02 Nov 2004 11:11:46 +0100, Harald Fuchs <[EMAIL PROTECTED]> wrote: > In article <[EMAIL PROTECTED]>, > > I guess this is an oversimplification. Often you can use a single SQL set > operation instead of a loop. Your example would probably be the same as > > UPDATE packet > SET timestamp

Re: Updating rows from a query

2004-11-02 Thread Harald Fuchs
In article <[EMAIL PROTECTED]>, Stephen Rasku <[EMAIL PROTECTED]> writes: > I am using the C API with MySQL 4.0.17 on QNX 6.2.1b. > I want to update the rows that are returned as I get them. Is this > possible. Here's a simplified version of what I am trying to do: > query = "select seqNo, prio

Re: Updating rows from a query

2004-11-01 Thread Paul DuBois
At 15:18 -0800 11/1/04, Stephen Rasku wrote: I am using the C API with MySQL 4.0.17 on QNX 6.2.1b. I want to update the rows that are returned as I get them. Is this possible. Here's a simplified version of what I am trying to do: query = "select seqNo, priority from packet where timestamp < now(