我寫了一段程式如下:
https://goo.gl/5aSVTS
但是會跳出以下錯誤:
https://goo.gl/qeG48a
https://goo.gl/eGQACV
google到的說法是context.xml設定的問題
但是我不管修改哪裡都還是一樣
可能是url或帳密寫錯
但是我把context.xml跟資料庫連線的內容作比較
context.xml:
https://goo.gl/ZOFOFA
oracle sql developer的連線設定:
https://goo.gl/AhnBKU
url跟帳密都是一樣的
web.xml:
https://goo.gl/KnzXKN
那這樣到底應該怎麼修改才好呢
--
※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 220.136.193.198
※ 文章網址: https://www.ptt.cc/bbs/java/M.1455297057.A.402.html
※ 編輯: lueichun (220.136.193.198), 02/13/2016 01:14:25
→
02/13 09:14, , 1F
02/13 09:14, 1F
→
02/13 09:18, , 2F
02/13 09:18, 2F
推
02/13 09:18, , 3F
02/13 09:18, 3F
→
02/13 09:18, , 4F
02/13 09:18, 4F
ojdbc6.jar有在c:tomcat\lib裡
https://goo.gl/54aaT2
entityManager:
https://goo.gl/VdGCfU
※ 編輯: lueichun (118.160.98.251), 02/13/2016 12:44:29
推
02/14 01:11, , 5F
02/14 01:11, 5F
修改後:
https://goo.gl/gtU6o4
https://goo.gl/47gLHW
https://goo.gl/NDvSlM
還是一樣的錯誤
※ 編輯: lueichun (118.160.98.251), 02/14/2016 01:35:20
→
02/14 15:55, , 6F
02/14 15:55, 6F
→
02/14 15:55, , 7F
02/14 15:55, 7F
→
02/14 15:58, , 8F
02/14 15:58, 8F
→
02/14 15:58, , 9F
02/14 15:58, 9F
→
02/14 15:58, , 10F
02/14 15:58, 10F
ORACLE driver的位置是oracle.jdbc.driver.OracleDriver
https://goo.gl/GVS6o4
※ 編輯: lueichun (220.136.193.140), 02/14/2016 20:27:27
→
03/15 00:12, , 11F
03/15 00:12, 11F
→
03/15 00:13, , 12F
03/15 00:13, 12F
→
03/15 00:14, , 13F
03/15 00:14, 13F