facebook

JPA reverse engineering does not work with Informix 11.7

  1. MyEclipse IDE
  2.  > 
  3. Java EE Development (EJB, JSP, Struts, XDoclet, etc.)
Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #341358 Reply

    Hello Everyone:

    I have a problem running MyEclipse JPA reverse engineering with Informix.database (no problems with my tables in MySql) also I’m not able to créate ddl script when table is selected.

    I’ve tried with JDBC drivers: 3.5 3.7 and 4.10. Using 3.5 version I can’t even display JPA reverse engineering options on the table.

    my setup:
    (Bling)
    MyEclipse Blue Edition

    Version: 10.6 Blue
    Build id: 10.6-Blue-20120727

    jdbc string: jdbc:informix-sqli://host:port/prueba:informixserver=PRUEBA

    stack trace:

    org.hibernate.exception.GenericJDBCException: Error while reading primary key meta data for pruebaema.informix.prueba
    at org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:103)
    at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:91)
    at org.hibernate.cfg.reveng.dialect.JDBCMetaDataDialect$4.handleSQLException(JDBCMetaDataDialect.java:171)
    at org.hibernate.cfg.reveng.dialect.ResultSetIterator.next(ResultSetIterator.java:62)
    at org.hibernate.cfg.reveng.JDBCReader.processPrimaryKey(JDBCReader.java:350)
    at org.hibernate.cfg.reveng.JDBCReader.readDatabaseSchema(JDBCReader.java:86)
    at com.genuitec.eclipse.hibernate.wizards.MEJDBCMetaDataConfiguration$1.readDatabaseSchema(MEJDBCMetaDataConfiguration.java:104)
    at org.hibernate.cfg.JDBCBinder.readFromDatabase(JDBCBinder.java:92)
    at com.genuitec.eclipse.hibernate.wizards.MEJDBCMetaDataConfiguration.readFromJDBC(MEJDBCMetaDataConfiguration.java:137)
    at com.genuitec.eclipse.hibernate.wizards.GenerateArtifactsJob$7.execute(GenerateArtifactsJob.java:888)
    at org.hibernate.console.execution.DefaultExecutionContext.execute(DefaultExecutionContext.java:64)
    at org.hibernate.console.ConsoleConfiguration.execute(ConsoleConfiguration.java:95)
    at com.genuitec.eclipse.hibernate.wizards.GenerateArtifactsJob.buildConfiguration(GenerateArtifactsJob.java:869)
    at com.genuitec.eclipse.hibernate.wizards.GenerateArtifactsJob.run(GenerateArtifactsJob.java:410)
    at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
    Caused by: java.sql.SQLException: No such column name
    at com.informix.util.IfxErrMsg.getSQLException(IfxErrMsg.java:413)
    at com.informix.jdbc.IfxScrollableResultSet.findColumn(IfxScrollableResultSet.java:210)
    at com.informix.jdbc.IfxScrollableResultSet.getString(IfxScrollableResultSet.java:675)
    at org.hibernate.cfg.reveng.dialect.JDBCMetaDataDialect.putTablePart(JDBCMetaDataDialect.java:111)
    at org.hibernate.cfg.reveng.dialect.JDBCMetaDataDialect$4.convertRow(JDBCMetaDataDialect.java:164)
    at org.hibernate.cfg.reveng.dialect.ResultSetIterator.next(ResultSetIterator.java:59)
    … 11 more

    my session data:

    eclipse.buildId=unknown
    java.version=1.6.0_13
    java.vendor=Sun Microsystems Inc.
    BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=es_MX
    Command-line arguments: -os win32 -ws win32 -arch x86

    SQLdrivers.xml: (3.70 driver versión)

    <Bean Class=”net.sourceforge.squirrel_sql.fw.sql.SQLDriver”>
    <driverClassName>com.informix.jdbc.IfxDriver</driverClassName>
    <identifier Class=”net.sourceforge.squirrel_sql.fw.id.UidIdentifier”>
    <string>-1a73da09:1405a9ba2a7:-7efe</string>
    </identifier>
    <jarFileName/>
    <jarFileNames Indexed=”true”>
    <Bean Class=”net.sourceforge.squirrel_sql.fw.util.beanwrapper.StringWrapper”>
    <string>C:\Program Files\IBM\Informix_JDBC_Driver370\lib\ifxjdbc.jar</string>
    </Bean>
    <Bean Class=”net.sourceforge.squirrel_sql.fw.util.beanwrapper.StringWrapper”>
    <string>C:\Program Files\IBM\Informix_JDBC_Driver370\lib\ifxjdbcx.jar</string>
    </Bean>
    <Bean Class=”net.sourceforge.squirrel_sql.fw.util.beanwrapper.StringWrapper”>
    <string>C:\Program Files\IBM\Informix_JDBC_Driver370\lib\ifxlang.jar</string>
    </Bean>
    <Bean Class=”net.sourceforge.squirrel_sql.fw.util.beanwrapper.StringWrapper”>
    <string>C:\Program Files\IBM\Informix_JDBC_Driver370\lib\ifxlsupp.jar</string>
    </Bean>
    <Bean Class=”net.sourceforge.squirrel_sql.fw.util.beanwrapper.StringWrapper”>
    <string>C:\Program Files\IBM\Informix_JDBC_Driver370\lib\ifxsqlj.jar</string>
    </Bean>
    <Bean Class=”net.sourceforge.squirrel_sql.fw.util.beanwrapper.StringWrapper”>
    <string>C:\Program Files\IBM\Informix_JDBC_Driver370\lib\ifxtools.jar</string>
    </Bean>
    </jarFileNames>
    <name>MyEclipseDriverName0123</name>
    <url>jdbc:informix-sqli://myHost:myPort/test:informixserver=PRUEBA</url>
    </Bean>

    my table script:

    CREATE TABLE informix.prueba(
    ID SERIAL NOT NULL,
    CampoLargo LVARCHAR,
    CountryCode VARCHAR(3) NOT NULL,
    District VARCHAR(20) NOT NULL,
    nombre VARCHAR(35) NOT NULL,
    Population INTEGER NOT NULL,
    Fecha DATE NOT NULL,
    FechaDatetime DATETIME HOUR to MINUTE NOT NULL,
    Airport SMALLINT,
    University CHAR(2) NOT NULL,
    Democracy BOOLEAN(1) NOT NULL,
    Archivo BLOB,
    datoflotante FLOAT NOT NULL,
    PRIMARY KEY (ID)
    )

    any help would be appreciated! thanks in advance

    Attachments:
    You must be logged in to view attached files.
    #341370 Reply

    support-swapna
    Moderator

    Ingericmartinez,

    Sorry that you are seeing this issue.

    1. Do you see this issue only with a particular table or with all the tables in the Informix DB ?

    2. Can you please try creating a sample table with a primary key which is in lower case (Id) to rule out any issues with case sensitivity ?

    3. Please list out the exact steps you followed while adding the JPA capabilities to the project. Please also attach a screenshot of the Informix DB connector along with the Driver name you selected to help us replicate the issue at our end.

    4. For the latest drivers which support Hibernate+Informix, checking the Hibernate support fourms might help.

    #341699 Reply

    I’ve tried with a lower case sql script, test results are same as before.

    Problem is PRIMARY KEY (ID)

    If primary key is omitted all code generation process seems to be ok

    new table script:

    CREATE TABLE informix.prueba(
    id SERIAL NOT NULL,
    campolargo LVARCHAR,
    countrycode VARCHAR(3) NOT NULL,
    district VARCHAR(20) NOT NULL,
    nombre VARCHAR(35) NOT NULL,
    population INTEGER NOT NULL,
    fecha DATE NOT NULL,
    fechadatetime DATETIME HOUR to MINUTE NOT NULL,
    airport SMALLINT,
    university CHAR(2) NOT NULL,
    democracy BOOLEAN(1) NOT NULL,
    archivo BLOB,
    datoflotante FLOAT NOT NULL,
    PRIMARY KEY (ID)
    )

    #341700 Reply

    My Informix driver Installation

    Attachments:
    You must be logged in to view attached files.
    #341755 Reply

    Ingericmartinez,

    Apologies for the delayed response. I could replicate the issue at our end. I have filed a PR for the dev team to investigate on this issue.

    Sorry for the inconvenience caused.

    #341902 Reply

    thanks

    #341923 Reply

    Ingericmartinez,

    Can you please try JPA reverse engineering by right clicking on the project and select MyEclipse > Generate Entities & DAO’s > Select DALI (only entity generation currently supported) > click OK and follow the wizard to perform reverse engineering. I’m afraid this is the only option we can offer at the moment while we investigate the issue.

    Sorry for the inconvenience caused.

    #341927 Reply

    I’ll be waiting this solved on future releases

    #341950 Reply

    Ingericmartinez,

    Thanks for your patience. We will inform you once the issue is resolved.

Viewing 9 posts - 1 through 9 (of 9 total)
Reply To: JPA reverse engineering does not work with Informix 11.7

You must be logged in to post in the forum log in