Subject | Re: [IBO] Generator values not udpated |
---|---|
Author | Ed Dressel |
Post date | 2008-11-07T15:00:48Z |
> a) the import utility seems to change (or not to change) thethe import utility gets a new generator value (as posted before). It
> current value of the *generator* ?
is the only place that the ID is accessed.
> b) the imported records are getting stored with their "generatEDthe imported records seem to be getting the correct generated IDs, but
> IDs" as they were in the database they were imported from ?
then, after the import, the new generator values is not kept--it
reverts back to its previous value.
For example, it was 130. 50 new records are added, and the records
have ID values values of 131...180. But then, after the import, the
generator is 130.
And I only see this very occasionally--very occasionally. But I have
seen it more then once.
I now check the generator values and IDs after the import, and if the
generator is less then the max ID value, I reset it--it is a work
around, but a bit ugly.
> c) something different to either, e.g. apparently sometimes one,sometimes the other...
>where the INSERT statement was going through as null, e.g.
> For c), do you have a trigger that would cause this in a situation
>I have that code in my trigger, but it would never be fired because
>
> if (new.id is null) then
> new.id = gen_id(TheSameGenerator,1);
the import utility needs the ID for detail records--so I get the ID
I don't know what more I can explain--it doesn't happen very often,
but when it does, it is ugly.
Thanks
Ed Dressel