【转】myeclipse下 Generating Artifacts 问题解决

1、在myeclipse中使用hibernate进行“Hibernate Reverse Engineering”报如下错:

An internal error occurred during: "Generating Artifacts".
Path must include project and resource name: /

找到工程下的 .myhibernatedata

修改为:

#
#Fri Dec 16 13:39:20 CST 2011
genBasicCompId=true
sessionFactoryName=com.pengpeng.model.domain.HibernateSessionFactory
profile=
daoSFId=
version=3.2
jndiPath=
detectM2M=false
reStrategyClass=
springDaoFile=
useJavaTypes=true
keyGenerator=
libInstallFolder=lib
addLibs2Project=true
genVersionTag=false
sessionFactoryId=
basePersistenceClass=
reSettingsFile=
configFile=/model/trunk/src/hibernate.cfg.xml
createConfigFile=true
addLibs2Classpath=true
baseDaoClass=BaseHibernateDAO

除了configFile目录自己写以外,其他的完全可以照抄,甚至configFile的路径不对都可以,我的工程下就没有/model/trunk/src/hibernate.cfg.xml

 

2、如下报错:
“This   wizard   generates   Hibernate   3.0.OR   mapping(*.hbm.xml). 
the   project   you   selected   is   a   Hibernate   2   project.Execution   of 
this   wizard   may   produce   incompatible   mapping   files "

解决:将version改成你自己的版本好就ok

你可能感兴趣的:(ssh)