netbeans数据库连接问题

来源:百度知道 编辑:UC知道 时间:2024/06/06 11:46:50
我用netbeans 6.7建了一个桌面应用程序,数据库用的是sql server 2005,主程序里面登陆连接数据库没问题,跳转到另外一个窗口时,窗口不出现,提示一大行的出错信息。那个窗口是一个table绑定到数据库表显示数据的。出错信息如下,哪位达人帮忙解答一下?

错误部分代码如下:

run:
Exception in thread "AWT-EventQueue-0" javax.persistence.PersistenceException: No Persistence provider for EntityManager named PU: Provider named oracle.toplink.essentials.PersistenceProvider threw unexpected exception at create EntityManagerFactory:
oracle.toplink.essentials.exceptions.PersistenceUnitLoadingException
Local Exception Stack:
Exception [TOPLINK-30005] (Oracle TopLink Essentials - 2.0.1 (Build b09d-fcs (12/06/2007))): oracle.toplink.essentials.exceptions.PersistenceUnitLoadingException
Exception Description: An exception was thrown while searching for persistence archives with ClassLoader: sun.misc.Launcher$AppClassLoader@19821f
Internal Exception: javax.persistence.PersistenceException: Exception [TOPLINK-28018] (Oracle TopLink Essentials - 2.0.1 (Build b09d-fc

你是在程序里自己写代码连接的还是用它给的从
服务--数据库--新建驱动--新建连接这样连接的?
如果已经连接成功的话
如果是后者的话看看你的绑定有没有问题吧。

应该是一个默认的错误,你的配置有问题