Resolve myeclipse4.1.1 to a table generated mapping file, the "Generating artifacts" solution appears!

Source: Internet
Author: User

Many people have problems with "generating artifacts" when generating mapping files for a table with myeclipse4.1.1. I also encountered this problem, made me also very depressed!
After reading a lot of people's posts still can not be done. Finally, you find the following error message by looking at the. metadata\.log File:
! ENTRY org.eclipse.core.runtime 4 2 2006-11-06 17:08:56.78
! MESSAGE An internal error occurred during: "Generating artifacts".
! STACK 0
Org.hibernate.exception.SQLGrammarException:Could not get list of tables from database. Probably a JDBC driver problem.
Configured Schema:null
Configured Catalog:default Catalog
Available schemas:
Available Catalogs:
Information_schema
Ito
Libraryweb
Mysql
Schoolproject
Test

At Org.hibernate.exception.SQLStateConverter.convert (sqlstateconverter.java:65)
At Org.hibernate.cfg.reveng.dialect.JDBCMetaDataDialect.getTables (jdbcmetadatadialect.java:94)
At Org.hibernate.cfg.reveng.JDBCReader.processTables (jdbcreader.java:395)
At Org.hibernate.cfg.reveng.JDBCReader.readDatabaseSchema (jdbcreader.java:65)
At Com.genuitec.eclipse.hibernate.wizards.mejdbcmetadataconfiguration$1.readdatabaseschema ( MEJDBCMETADATACONFIGURATION.JAVA:102)
At Org.hibernate.cfg.JDBCBinder.readFromDatabase (jdbcbinder.java:87)
At Com.genuitec.eclipse.hibernate.wizards.MEJDBCMetaDataConfiguration.readFromJDBC ( mejdbcmetadataconfiguration.java:129)
At Com.genuitec.eclipse.hibernate.wizards.generateartifactsjob$5.execute (generateartifactsjob.java:405)
At Org.hibernate.console.execution.DefaultExecutionContext.execute (defaultexecutioncontext.java:35)
At Org.hibernate.console.ConsoleConfiguration.execute (consoleconfiguration.java:68)
At Com.genuitec.eclipse.hibernate.wizards.GenerateArtifactsJob.buildConfiguration (generateartifactsjob.java:400 )
At Com.genuitec.eclipse.hibernate.wizards.GenerateArtifactsJob.run (generateartifactsjob.java:266)
At Org.eclipse.core.internal.jobs.Worker.run (worker.java:76)
caused by:java.sql.SQLException:Syntax error or access violation, message from server: "Unknown database ' default Catal OG ' "
At Com.mysql.jdbc.MysqlIO.checkErrorPacket (mysqlio.java:1876)
At Com.mysql.jdbc.MysqlIO.sendCommand (mysqlio.java:1098)
At Com.mysql.jdbc.MysqlIO.sqlQueryDirect (mysqlio.java:1192)
At Com.mysql.jdbc.MysqlIO.sqlQuery (mysqlio.java:1153)
At Com.mysql.jdbc.Connection.execSQL (connection.java:2048)
At Com.mysql.jdbc.Connection.execSQL (connection.java:2005)
At Com.mysql.jdbc.Statement.executeQuery (statement.java:1156)
At Com.mysql.jdbc.DatabaseMetaData.getTables (databasemetadata.java:3342)
At Org.hibernate.cfg.reveng.dialect.JDBCMetaDataDialect.getTables (jdbcmetadatadialect.java:70)
... One more

It looks like the database driver was a disaster. My configuration is: eclipse3.1.2+myeclipse4.1.1+mysql5.0.12. The database driver is using the latest Mysql-connector-java-5.0.4-bin.jar. It's strange why such a problem still arises.
Finally, try to db-browser the configuration page schema datails at the time of connection to the Dispaly all schema and then connect, and the result can generate a mapping file for the table.
It looks strange, Alex.
I hope that when you encounter this problem, take a look at the Eclipse\workspace\.metadata.metadata\.log file, you can solve the problem according to the error prompt.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.