UpdateHandler and auto-increment

User dfeb81947d

07-11-2005 09:48:06

Dear Support,





Since the early version of JChem, I was using an application to import the molecules from a table to JChem Structure Table using UpdateHandler.INSERT_WITH_ID because the result of a structure search are CD_ID and we wanted CD_ID to be our primary key.


As INSERT_WITH_ID is deprecated and CD_ID is incremented automatically, is there a way to change it without needing to make a SQL update?





Does the use of setValuesForFixColumns changed since INSERT_WITH_ID is deprecated?





Kind Regards


Jacques

ChemAxon 9c0afc9aaf

08-11-2005 15:28:36

Hi Jacques,
Quote:
As INSERT_WITH_ID is deprecated and CD_ID is incremented automatically, is there a way to change it without needing to make a SQL update?
No.


You cannot even an SQL update for either this


(apart from violating cache integrity it would result in an exception for most databases).
Quote:
Does the use of setValuesForFixColumns changed since INSERT_WITH_ID is deprecated?
No.


We progress cautiously when introducing such a major change, so first only deprecating, and later changing the code.





The idea behind the change was that most companies use globally unique alphanumeric identifiers for their compounds.


By only allowing auto-increment some operations could be a bit quicker.





Since this change would cause a problem for you as an existing user (and probably for others too) and the lost benefits are marginal, we have reconsidered this issue and will keep this insert mode.


It will not be deprecated in future release versions.








Best regards,





Szilard

User dfeb81947d

14-11-2005 11:01:00

Thank you so far, it helps a lot.


It seems that jchem 3.1.3 use this functionnality.


That's great. Thank you so far.