in reply to Cannot Read Back Record After Updating in Class::DBI

I see the problem. You are assigning the result of your second retrieve back to the same variable, without ever letting it go out of scope. This is interfering with the new "single instance" feature in the 0.96 release. You can disable this feature by running this code after Class::DBI is loaded:
$Class::DBI::Weaken_Is_Available = 0;

Replies are listed 'Best First'.
Fixed!
by Wally Hartshorn (Hermit) on Jul 19, 2004 at 15:04 UTC

    Ah ha! Thanks, perrin! You put your finger on the problem. I changed the code to update the record with one variable, then read it back with a different one, and that solved the problem.

    Is that the feature described in the 0.96 changes document as "Maintain live object index so subsequent requests for same row return the same object"? Or is that something else?

    I'm going to have to take a look at our other programs, because I'm sure we have some that are going to be bitten by the same problem. Hmm....

    Thanks again!

    Wally Hartshorn

      Yes, it is the live object index feature. There is a section in the documentation that describes it. Glad to hear you got it working.