REST structure search not working with regenerated old db

User 9f246fa673

07-10-2016 18:51:09

We have SQLServer with a JChem 5.11.2 database.  I have regenerated the chemistry table using JChemManager64 version 16.9.26.  Using the latest REST Web Service (19.9.5) from Chrome with this url:


http://localhost:8008/webservices/rest-v0/data/jchem_user2/table/testmols/search?queryStructure=CC1=C(C)C=CC=C1&limit=10


I get this error:-


{"errorCode":0,"errorMessage":"This table needs to be regenerated for the current JChem version. Contact your administrator!","rootCause":"java.lang.IllegalStateException"}


 


I got the same message before I did the regeneration.


I have restarted the Tomcat server.


I have tried single and double quotes around the SMILES to no effect.


Without the structure search things work e.g.:-


http://localhost:8008/webservices/rest-v0/data/jchem_user2/table/testmols/search?limit=10&limit=2


gives back a screed of JSON, so the connection is good.


Any ideas?


 


 

User 9f246fa673

10-10-2016 16:27:31

When I add an offset (still with no structure search) I get another error.


http://localhost:8008/webservices/rest-v0/data/jchem_user2/table/testmols/search?offset=10&limit=2


gives the error:-


{"errorCode":1,"errorMessage":"Invalid column name \u0027_ROWID\u0027.","rootCause":"SQLException","rootErrorMessage":"Invalid column name \u0027_ROWID\u0027."}


    Btw I have tried all of the above with the sample database and table ChEBI_lite_3star and everything works as expected with no errors.


 



ChemAxon 13811e1703

17-10-2016 06:31:34

Hi Jim,

If you are using JChem Web Services together with JChem Manager on the same database please make sure to use the same version of both. Although it is recommended to do regeneration and any other database modification through the web service api.

What kind of database are you using? Which version?

Regards,
Peter 

User 9f246fa673

18-10-2016 17:47:32

The problem was a different version of JCHEM (16.9.28) from JWS (16.9.5 {latest available}).   (Thank you Szilard Dorant for advice in a separate communication).


I downgraded JChem to 16.9.5 and I can now do structure queries (the first post on the thread).  However I still get the same error as before for a query with no structure but search?offset=10&limit=10 (my second post).  I will try another recalculation in JChemManager and see if that helps...   It didn't help.