Search Postgresql Archives

Re: SELECT Query returns empty

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



am  Wed, dem 09.07.2008, um 16:32:11 +0800 mailte Bright D.L. folgendes:
> The scenario:
>             There are two separate processes ? one (P1) inserting (not
> updating) data to a table at a high rate (around one record in 10ms) and
> another (P2) selecting the data from the same table for further processing. P1
> and P2 use separate connection to the Database and P1 sends a trigger to P2
> after inserting the data to the PostgreSQL.

What do you mean with 'P1 sends a TRIGGER to P2'? You can't send a
TRIGGER to another process.

> 
>  
> 
> The issue:
> 
>             P2 tries to query the data from the table, and the result set is
> empty. I modified the logic to send the trigger only after making sure that P1
> can successfully query the last record it inserted.
> 
>  
> 
> I would like to know why P1 can retrieve the data from the table while P2
> can?t.

Wild guess (maybe i misunderstand you): You insert the Data with P1
within a TRANSACTION and you haven't commited this insert. In this case,
P2 can't see the uncommited data.



Andreas
-- 
Andreas Kretschmer
Kontakt:  Heynitz: 035242/47150,   D1: 0160/7141639 (mehr: -> Header)
GnuPG-ID:   0x3FFF606C, privat 0x7F4584DA   http://wwwkeys.de.pgp.net


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux