issue connecting with IJC

User ea78dc1699

11-07-2013 19:14:22

I just had a mysql database set up. I can connect with jchem manager and create /edit schema but I am not able to connect using IJC. Am using 6.0 version of jchem and IJChem.


Here is the error that is created


Error creating bean with name 'ijcMetadataDao' defined in URL [jar:file:/C:/Program%20Files/ChemAxon/InstantJChem/instantjchem/modules/com-im-ijc-server-impl.jar!/META-INF/spring/applicationContext-shared-server-and-local-beans.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [com.im.ijcs.impl.dao.IJCMetadataDao]: Constructor threw exception; nested exception is java.lang.RuntimeException: org.springframework.jdbc.UncategorizedSQLException: StatementCallback; uncategorized SQLException for SQL [CREATE TABLE IJC_CUSTOM_ITEMS_SHARING (


SCHEMA_ID              VARCHAR(32)      NOT NULL,


CUSTOM_ITEM_ID         VARCHAR(32)      NOT NULL,


AUTHORITY              VARCHAR(50)      NOT NULL,


PRIV                   VARCHAR(100)      NOT NULL,


CONSTRAINT PK_IJC_CUSTOM_ITEMS_SHARING PRIMARY KEY (SCHEMA_ID, CUSTOM_ITEM_ID, AUTHORITY, PRIV),


CONSTRAINT FK_IJC_CUSTOM_ITEMS_SHARING FOREIGN KEY (SCHEMA_ID, CUSTOM_ITEM_ID) REFERENCES IJC_CUSTOM_ITEMS (SCHEMA_ID, ID) ON DELETE CASCADE,


CONSTRAINT FK_IJC_C_I_S_AUHORITY FOREIGN KEY (AUTHORITY) REFERENCES IJC_AUTHORITIES (AUTHORITY) ON DELETE CASCADE


) ENGINE=InnoDB DEFAULT CHARSET=utf8]; SQL state [HY000]; error code [1005]; Can't create table 'ijc_db.ijc_custom_items_sharing' (errno: 150); nested exception is java.sql.SQLException: Can't create table 'ijc_db.ijc_custom_items_sharing' (errno: 150)

ChemAxon 2bdd02d1e5

12-07-2013 04:50:40

The error states that some referenced tables or keys in a foreign key probably not exist.
Was this ever working with IJC 6.0? Which was the previous version you used?


I suggest to try following procedure:
1. uninstall IJC
2. download the latest version (6.0.2) and install it
3. enable SQL logging -> http://www.chemaxon.com/instantjchem/ijc_latest/docs/admin/debug_info.html#sql  />4. restart IJC and try to open your project


If this does not help, could you send us (you may use my email if prefered) complete IJC log file -> http://www.chemaxon.com/instantjchem/ijc_latest/docs/admin/debug_info.html#logfile


Thanks,


Filip