On 1/14/2013 12:15 AM, Condor wrote:
>
> When I call the function from php everything it's seems to work,
> but some time modify records just disappear. I don't have any ideas
> for the moment
> what is the problem in my postgresql or in my php code. I'm sure there
> was a recording was made.
> I run in middle night vacuum, reindex on tables and vacuum analyze;
> I check my postgresql logs, but no any errors. I check the php logs,
> but no errors.
> My vacuum also did not log any error messages. This problem happened
> one or two times per month
> and I can't track him. Is not happened very often. My question is: Is
> there any chance this function
> to stay opened or some thing like that and on the night when vacuum is
> started to rollback changes ?
> Also any other suggestions are welcome.
are you calling these functions within the context of a larger
transaction, or just as standalone statements without an epxlicit BEGIN
TRANSACTION ? if they are being called from within a transaction, and
something else in that transaction triggers a rollback, then ALL of the
changes made in that transaction go away. once a transaction is
committed, nothing can undo it, other than restoring a backup or
changing the data explicitly in another transaction, or something.