您好:书名:学通java的24堂课 本书的22.24.4节 执行时出现了Unknown database 'db_jxc'错误,辛苦老师帮忙解决,感谢。
发表在Java视频课程答疑 2019-04-02
是否精华
版块置顶:

您好:书名:学通java的24堂课 本书的22.24.4节 执行时出现了Unknown database 'db_jxc'错误,书上说是数据库公共类中db_jxc数据库名称不对,但我看了数据库名称db_jxc是对的,不知道是什么问题?第二个问题:MainFrame.java文件一直提示错误。辛苦老师帮忙解决,感谢。

MainFrame.java文件一直提示错误.jpg

解决方法.jpg

问题截图.jpg


分享到:
精彩评论 4
根号申
学分:4736 LV12
TA的每日心情
2021-07-16 23:48:46
2019-04-02
沙发
  1. 你自己编写一个JDBC测试代码,看是否能链接上这个数据库表。输出一下Connection对象看是不是null,null就是连不上。

  2. 不要只给红叉截图,红叉只能说明这个类有错误,具体是什么错误看eclipse的错图提示。

zhouyouSQ
学分:5 LV1
2019-04-02
板凳

根号申 发表于2019-04-02 14:11

  1. 你自己编写一个JDBC测试代码,看是否能链接上这个数据库表。输出一下Connection对象看是不是null,null就是连不上。

  2. 不要只给红叉截图,红叉只能说明这个类有错误,具体是什么错误看eclipse的错图提示。

Exception in thread "AWT-EventQueue-0" java.lang.Error: 无法解析的编译问题:


at zzk.zhuoyue.daohang.MainDaohangFrame.launch(MainFrame.java:1283)

at zzk.zhuoyue.daohang.LoginFrame$PanelBack.btn_enterActionPerformed(LoginFrame.java:256)

at zzk.zhuoyue.daohang.LoginFrame$PanelBack.pwd_passwordActionPerformed(LoginFrame.java:293)

at zzk.zhuoyue.daohang.LoginFrame$PanelBack.access$1(LoginFrame.java:292)

at zzk.zhuoyue.daohang.LoginFrame$PanelBack$2.actionPerformed(LoginFrame.java:193)

at javax.swing.JTextField.fireActionPerformed(JTextField.java:492)

at javax.swing.JTextField.postActionEvent(JTextField.java:705)

at javax.swing.JTextField$NotifyAction.actionPerformed(JTextField.java:820)

at javax.swing.SwingUtilities.notifyAction(SwingUtilities.java:1636)

at javax.swing.JComponent.processKeyBinding(JComponent.java:2849)

at javax.swing.JComponent.processKeyBindings(JComponent.java:2884)

at javax.swing.JComponent.processKeyEvent(JComponent.java:2812)

at java.awt.Component.processEvent(Component.java:5993)

at java.awt.Container.processEvent(Container.java:2041)

at java.awt.Component.dispatchEventImpl(Component.java:4583)

at java.awt.Container.dispatchEventImpl(Container.java:2099)

at java.awt.Component.dispatchEvent(Component.java:4413)

at java.awt.KeyboardFocusManager.redispatchEvent(KeyboardFocusManager.java:1848)

at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(DefaultKeyboardFocusManager.java:704)

at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(DefaultKeyboardFocusManager.java:969)

at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(DefaultKeyboardFocusManager.java:841)

at java.awt.DefaultKeyboardFocusManager.dispatchEvent(DefaultKeyboardFocusManager.java:668)

at java.awt.Component.dispatchEventImpl(Component.java:4455)

at java.awt.Container.dispatchEventImpl(Container.java:2099)

at java.awt.Window.dispatchEventImpl(Window.java:2475)

at java.awt.Component.dispatchEvent(Component.java:4413)

at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)

at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)

at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)

at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)

at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)

at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)

at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

Exception in thread "AWT-EventQueue-0" java.lang.Error: 无法解析的编译问题:


zhouyouSQ
学分:5 LV1
2019-04-02
地板

zhouyouSQ 发表于2019-04-02 16:14

Exception in thread "AWT-EventQueue-0" java.lang.Error: 无法解析的编译问题:


at zzk.zhuoyue.daohang.MainDaohangFrame.launch(MainFrame.java:1283)

at zzk.zhuoyue.daohang.LoginFrame$PanelBack.btn_enterActionPerformed(LoginFrame.java:256)

at zzk.zhuoyue.daohang.LoginFrame$PanelBack.pwd_passwordActionPerformed(LoginFrame.java:293)

at zzk.zhuoyue.daohang.LoginFrame$PanelBack.access$1(LoginFrame.java:292)

at zzk.zhuoyue.daohang.LoginFrame$PanelBack$2.actionPerformed(LoginFrame.java:193)

at javax.swing.JTextField.fireActionPerformed(JTextField.java:492)

at javax.swing.JTextField.postActionEvent(JTextField.java:705)

at javax.swing.JTextField$NotifyAction.actionPerformed(JTextField.java:820)

at javax.swing.SwingUtilities.notifyAction(SwingUtilities.java:1636)

at javax.swing.JComponent.processKeyBinding(JComponent.java:2849)

at javax.swing.JComponent.processKeyBindings(JComponent.java:2884)

at javax.swing.JComponent.processKeyEvent(JComponent.java:2812)

at java.awt.Component.processEvent(Component.java:5993)

at java.awt.Container.processEvent(Container.java:2041)

at java.awt.Component.dispatchEventImpl(Component.java:4583)

at java.awt.Container.dispatchEventImpl(Container.java:2099)

at java.awt.Component.dispatchEvent(Component.java:4413)

at java.awt.KeyboardFocusManager.redispatchEvent(KeyboardFocusManager.java:1848)

at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(DefaultKeyboardFocusManager.java:704)

at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(DefaultKeyboardFocusManager.java:969)

at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(DefaultKeyboardFocusManager.java:841)

at java.awt.DefaultKeyboardFocusManager.dispatchEvent(DefaultKeyboardFocusManager.java:668)

at java.awt.Component.dispatchEventImpl(Component.java:4455)

at java.awt.Container.dispatchEventImpl(Container.java:2099)

at java.awt.Window.dispatchEventImpl(Window.java:2475)

at java.awt.Component.dispatchEvent(Component.java:4413)

at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)

at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)

at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)

at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)

at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)

at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)

at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

Exception in thread "AWT-EventQueue-0" java.lang.Error: 无法解析的编译问题:


现在不报任何错误,但是在Eclipse控制台中一直返回这些错误消息。

根号申
学分:4736 LV12
TA的每日心情
2021-07-16 23:48:46
2019-04-03
4L

看无法编译的代码中红色狼线的错误提示

首页上一页 1 下一页尾页 4 条记录 1/1页
手机同步功能介绍
友情提示:以下图书配套资源能够实现手机同步功能
明日微信公众号
明日之星 明日之星编程特训营
客服热线(每日9:00-17:00)
400 675 1066
mingrisoft@mingrisoft.com
吉林省明日科技有限公司Copyright ©2007-2022,mingrisoft.com, All Rights Reserved长春市北湖科技开发区盛北大街3333号长春北湖科技园项目一期A10号楼四、五层
吉ICP备10002740号-2吉公网安备22010202000132经营性网站备案信息 营业执照