Java exception connecting to MySQL as "normal user"

User d329696e7a

12-09-2007 19:52:13

for Instant JChem 2.0 running on Mac OS 10.4.10, G4 with MySQL 4.1.18





I'm just beginning the process of trying out/evaluating the capabilities. I was able to connect to a MySQL database on the same machine as the "schema owner" and create a table and add a row, but when I attempt to connect as a "normal user", it fails with a Java exception:


Code:



java.lang.NullPointerException


   at com.im.df.impl.db.sprovider.DDLModeSelectionState.proceedToNextState(DDLModeSelectionState.java:187)


   at com.im.df.impl.db.sprovider.SchemaProviderImpl.proceedToNextState(SchemaProviderImpl.java:98)


   at com.im.ijc.core.api.util.SchemaInitManager.startInit(SchemaInitManager.java:139)


   at com.im.ijc.core.api.util.SchemaInitManager.access$000(SchemaInitManager.java:47)


   at com.im.ijc.core.api.util.SchemaInitManager$1.run(SchemaInitManager.java:68)


   at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:539)


[catch] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:964)











and this is what's shown in the messages window:


Code:



Error: Failed to read Entity D4547F6EDF638B26D32E6D8207D86B5F for Schema 75B50065C12AE6AB3505BEE74B910DDE [ jchem test mysql ]


The XML was probably invalid and the Entity must be ignored.


Please contact your database administrator.


This problem may be correctable.


Additional information will be in the logs.


java.lang.IllegalArgumentException: Entity has already been registered


        at com.im.df.impl.db.DBSchemaManager.registerEntity(DBSchemaManager.java:253)


        at com.im.df.impl.db.DBSchemaManager.addEntity(DBSchemaManager.java:226)


        at com.im.df.impl.db.persist.DBSchemaPersistenceImpl$ClientSeverDBEntityJChemBasePersistence.associate(DBSchemaPersistenceImpl.java:938)


        at com.im.df.impl.db.persist.DBSchemaPersistenceImpl$ClientSeverDBEntityJChemBasePersistence.associate(DBSchemaPersistenceImpl.java:884)


        at com.im.df.impl.db.entity.DBEntityAbstractImpl.connectExisting(DBEntityAbstractImpl.java:308)


        at com.im.df.impl.db.persist.DBSchemaPersistenceImpl$ClientSeverDBEntityJChemBasePersistence.createFromXml(DBSchemaPersistenceImpl.java:1051)


        at com.im.df.impl.db.persist.DBSchemaPersistenceImpl$ClientSeverDBEntityJChemBasePersistence.createFromXml(DBSchemaPersistenceImpl.java:884)


        at com.im.df.impl.db.sprovider.DDLModeSelectionState.readSchema(DDLModeSelectionState.java:274)


        at com.im.df.impl.db.sprovider.DDLModeSelectionState.proceedToNextState(DDLModeSelectionState.java:149)


        at com.im.df.impl.db.sprovider.SchemaProviderImpl.proceedToNextState(SchemaProviderImpl.java:98)


        at com.im.ijc.core.api.util.SchemaInitManager.startInit(SchemaInitManager.java:139)


        at com.im.ijc.core.api.util.SchemaInitManager.access$000(SchemaInitManager.java:47)


        at com.im.ijc.core.api.util.SchemaInitManager$1.run(SchemaInitManager.java:68)


        at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:539)


        at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:964)


Warning: Failed to read Data Tree 7A5B276789825C5ABABD88E614D82391 for Schema 75B50065C12AE6AB3505BEE74B910DDE [ jchem test mysql ]


An item required by this DataTree was missing.


The cause was: Root entity of Data Tree is missing. Data Tree cannot be created


Please look for earlier errors that could have caused this.






Am I missing some step in terms of the setup?

User d329696e7a

12-09-2007 21:17:19

note: problem still occurs after I upgraded to the latest MySQL 5.0.45

ChemAxon e189db4705

12-09-2007 21:33:36

Could you check if you use the latest IJC update (version 2.0.2)?


If not, please, go to menu Tools->Plugins and update IJC. I think this problem should be already solved.

User d329696e7a

13-09-2007 13:28:11

updating to 2.0.2 solves the problem with connecting as a "normal user" to MySQL- thanks.