标题:MyEclipse+Hibernate连接MSSQL数据库总是could not execute query
取消只看楼主
wangliwei
Rank: 1
等 级:新手上路
帖 子:19
专家分:0
注 册:2007-7-14
 问题点数:0 回复次数:0 
MyEclipse+Hibernate连接MSSQL数据库总是could not execute query

使用MyEclipse自带的Hibernate插件功能尝试连接MSSQL数据库
<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">

<!-- Generated by MyEclipse Hibernate Tools. -->
<hibernate-configuration>

<session-factory>
<property name="myeclipse.connection.profile">con_denglu</property>
<property name="connection.driver_class">com.microsoft.jdbc.sqlserver.SQLServerDriver</property>
<property name="connection.url">jdbc:microsoft:sqlserver://127.0.0.1:1433;DatabaseName=ChinaSpace</property>
<property name="connection.username">sa</property>
<property name="connection.password">123</property>
<property name="dialect">org.hibernate.dialect.SQLServerDialect</property>

<property name="show_sql">false</property>
执行的时候报错:
org.apache.jasper.JasperException: Exception forwarding for name indexToMain: javax.servlet.ServletException: could not execute query
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:510)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:375)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

搜索更多相关主题的帖子: Hibernate MyEclipse 数据库 MSSQL execute 
2007-07-17 09:26



参与讨论请移步原网站贴子:https://bbs.bccn.net/thread-155926-1-1.html




关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.985907 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved