关于表单提交,日期类型处理 报错信息不支持从 UNKNOWN 到 UNKNOWN 的转换。

c3p0连接已测,其他正常 只有添加功能报错
数据库中birthday为datetime类型
报错信息和关键代码贴出

java.sql.SQLException: 不支持从 UNKNOWN 到 UNKNOWN 的转换。 Query: insert into stu (sname,sex,sphone,sbirthday,shobby,sinfo) values(?,?,?,?,?,?) Parameters: [aa, 男, 21332132, Sun Dec 30 17:21:15 CST 2018, 游泳, s]
    at org.apache.commons.dbutils.AbstractQueryRunner.rethrow(AbstractQueryRunner.java:320)
    at org.apache.commons.dbutils.QueryRunner.update(QueryRunner.java:489)
    at org.apache.commons.dbutils.QueryRunner.update(QueryRunner.java:455)
    at com.dao.impl.StudentDaoImpl.insert(StudentDaoImpl.java:32)
    at com.service.impl.StudentServiceImpl.insert(StudentServiceImpl.java:30)
    at com.servlet.AddStudentServlet.doGet(AddStudentServlet.java:57)
    at com.servlet.AddStudentServlet.doPost(AddStudentServlet.java:82)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:648)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:292)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
    at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:212)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:94)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:141)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
    at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:620)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:502)
    at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1132)
    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:684)
    at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1539)
    at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1495)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    at java.lang.Thread.run(Unknown Source)
AddStudentServlet.java
package com.servlet;

import java.io.IOException;
import java.sql.SQLException;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;

import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import com.damain.Student;
import com.service.StudentService;
import com.service.impl.StudentServiceImpl;

/**
 * Servlet implementation class AddStudentServlet
 */
@WebServlet("/AddStudentServlet")
public class AddStudentServlet extends HttpServlet {
    private static final long serialVersionUID = 1L;

    /**
     * @see HttpServlet#HttpServlet()
     */
    public AddStudentServlet() {
        super();
        // TODO Auto-generated constructor stub
    }

    /**
     * @see HttpServlet#doGet(HttpServletRequest request, HttpServletResponse response)
     */
    protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
        // TODO Auto-generated method stub

        try {
            //获取数据
            request.setCharacterEncoding("UTF-8");
            String name = request.getParameter("sname");
            String sex = request.getParameter("sex");
            String phone = request.getParameter("sphone");
            String birthday = request.getParameter("sbirthday"); 
            String hobby = request.getParameter("shobby");
            String info = request.getParameter("sinfo");
            //String转为date
            SimpleDateFormat sdf1 =new SimpleDateFormat("YYYY-MM-dd hh:mm:ss");
            //添加到数据库
            Date date;
            try {
                date = sdf1.parse(birthday);
                StudentService service = new StudentServiceImpl();
                Student student = new Student(name,sex,phone,date,hobby,info);
                service.insert(student);

                //跳转到列表页


                request.getRequestDispatcher("StudentListServlet").forward(request, response);
            } catch (ParseException e) {
                // TODO Auto-generated catch block
                e.printStackTrace();
            }

        } catch (SQLException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        }

    }

    /**
     * @see HttpServlet#doPost(HttpServletRequest request, HttpServletResponse response)
     */
    protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
        // TODO Auto-generated method stub
        doGet(request, response);
    }

}
Student.java
package com.damain;

import java.util.Date;

/*
 * 这是学生封装的对象bean 
 */
public class Student {
private int sid;
private String sname;
private String sex;
private String sphone;
private Date sbirthday;
private String shobby;
private String sinfo;


public Student() {
    super();
}
public Student( String sname, String sex, String sphone, Date sbirthday, String shobby, String sinfo) {
    super();
    this.sname = sname;
    this.sex = sex;
    this.sphone = sphone;
    this.sbirthday = sbirthday;
    this.shobby = shobby;
    this.sinfo = sinfo;
}
public int getSid() {
    return sid;
}
public void setSid(int sid) {
    this.sid = sid;
}
public String getSname() {
    return sname;
}
public void setSname(String sname) {
    this.sname = sname;
}
public String getSex() {
    return sex;
}
public void setSex(String sex) {
    this.sex = sex;
}
public String getSphone() {
    return sphone;
}
public void setSphone(String sphone) {
    this.sphone = sphone;
}
public Date getSbirthday() {
    return sbirthday;
}
public void setSbirthday(Date sbirthday) {
    this.sbirthday = sbirthday;
}
public String getShobby() {
    return shobby;
}
public void setShobby(String shobby) {
    this.shobby = shobby;
}
public String getSinfo() {
    return sinfo;
}
public void setSinfo(String sinfo) {
    this.sinfo = sinfo;
}

}

package com.dao.impl;


import java.sql.SQLException;
import java.util.List;

import org.apache.commons.dbutils.QueryRunner;
import org.apache.commons.dbutils.handlers.BeanListHandler;
import org.junit.Test;

import com.damain.Student;
import com.dao.StudentDao;
import com.util.JDBCUtil;

/*
 * 这是StudentDao的实现
 */
public class StudentDaoImpl implements StudentDao {

    @Override
    public List<Student> findall() throws SQLException {
        // TODO Auto-generated method stub
        QueryRunner runner = new QueryRunner(JDBCUtil.getDataSource());
        List<Student> list =runner.query("Select * from stu",new BeanListHandler<Student>(Student.class));
        return list;
    }

    @Override
    public void insert(Student student) throws SQLException {
        // TODO Auto-generated method stub
        QueryRunner runner = new QueryRunner(JDBCUtil.getDataSource());
        runner.update("insert into stu (sname,sex,sphone,sbirthday,shobby,sinfo) values(?,?,?,?,?,?)",
                student.getSname(),
                student.getSex(),
                student.getSphone(),
                student.getSbirthday(),
                student.getShobby(),
                student.getSinfo()
                );
    }
0

1个回答

最后runner.update传string吧,传date应该也是调用toString

0
gsh1075035316
gsh1075035316 呃 不是太明白 那个 我觉得 问题确实是birthday的date属性 我试了 我用String替换掉birthday的date 是可以插入的 难道以后表单里和实体中碰见日期型数据 我都用String吗?所以很疑惑 请指教 好吧?
4 个月之前 回复
Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
mssql在JDBC通用更新时出现 不支持从 UNKNOWN 到 UNKNOWN 的转换。
在你的实体类文件中定义了两个Date类型,改掉一个就行
HistCite 导入类型 unknown 解决办法
在网上看了很多方法,摸索出来的。现在分享给大家:1.确保文件的路径中没有中文,文件名没有&quot;&quot;等特殊字符。2.把下载的txt文件的第一行替换成: FN Thomson Reuters Web of KnowledgeVR 。(我这一步解决了)3.若 1.和 2.不行的话,试试把下载的txt文件另存为txt 文件,编码选择 ANSI。4.若1. 2. 和3. 还是不行的话,把第一行换成FN ISI E...
Unknown Treasure
Problem DescriptionnOn the way to the next secret treasure hiding place, the mathematician discovered a cave unknown to the map. The mathematician entered the cave because it is there. Somewhere deep in the cave, she found a treasure chest with a combination lock and some numbers on it. After quite a research, the mathematician found out that the correct combination to the lock would be obtained by calculating how many ways are there to pick m different apples among n of them and modulo it with M. M is the product of several different primes.n nnInputnOn the first line there is an integer T(T≤20) representing the number of test cases.nnEach test case starts with three integers n,m,k(1≤m≤n≤1018,1≤k≤10) on a line where k is the number of primes. Following on the next line are k different primes p1,...,pk. It is guaranteed that M=p1⋅p2⋅⋅⋅pk≤1018 and pi≤105 for every i∈1,...,k.n nnOutputnFor each test case output the correct combination on a line.n nnSample Inputn1n9 5 2n3 5n nnSample Outputn6
for unknown purpose
it is a rubbish, nonsense
UnKnown DATABASE?
已经在INTERBASE里建立了数据库 MYDATA 了rn也在BDE里设置好了别名DBDATA 并指向数据库的路径了,为什么还会出现这个提示呢?rnrnProject gc.exe raised exception class EDBEngineError with message'UnKnown rndatabase.rnUnable to complete network request to host"IB_SERVER".rnFailed to locate host machine.rnThe specified name was not found in thernGeneral SQL error.rnhosts file or Domain Name Services.rnAlias:my data'.Process stopped.rnrn该怎么办呢?
tsm 定义dr unknown问题处理
系统:aix6.1 硬件:p720 此tsmserver上之前已经管理3584,我现在添加一台3310. tsm: TSM>define path tsm3310drive00 srctype=server desttype=drive library=3310LIB device=/dev/rmt38online=yes ANR8972E DEFINE PATH: Unable tofi
未登录词处理优秀论文——Pointing the Unknown Words
论文: 《Pointing the Unknown Words》 作者: Caglar Gulcehre、Sungjin Ahn、Ramesh Nallapati、Bowen Zhou、Yoshua Bengio这篇论文主要是解决低频词和未出现(在测试集中)词的问题——统称“未登录词问题”。 采用了注意力模型。本文的思想是在遇到未登录词时,不要简单的将其记作:UNK,而是将未登录词分作两种情
处理删除操作时出现 Unknown entity: java.lang.Integer
部分关键代码rn--------Subject.hbm.xmlrn rn rn rn rn------SubjectDao:rnpublic void delete(int persistentInstance) rn log.debug("deleting Subject instance");rn try rn getHibernateTemplate().delete(persistentInstance);//这是第57行rn log.debug("delete successful");rn catch (RuntimeException re) rn log.error("delete failed", re);rn throw re;rn rn rn-------SubjectBizrnpublic void deleteSubject(int subjectID)rn isubjectdao.delete(subjectID);//这是第75行rn rn--------SubjectActionrnpublic String deleteSubject()rn isubjectbiz.deleteSubject(subjectId);rn return SUCCESS;rn rn--------Struts.xmlrnrn /FenYeSubjectAction.actionrn rnrn我用的是Struts2,Hibernate,Spring框架做的rn老是报一下错误(精简下):rnorg.hibernate.MappingException: Unknown entity: java.lang.Integerrn org.hibernate.impl.SessionFactoryImpl.getEntityPersister(SessionFactoryImpl.java:550)rn org.hibernate.impl.SessionImpl.getEntityPersister(SessionImpl.java:1338)rn org.hibernate.event.def.DefaultDeleteEventListener.onDelete(DefaultDeleteEventListener.java:78)rn org.hibernate.event.def.DefaultDeleteEventListener.onDelete(DefaultDeleteEventListener.java:52)rn org.hibernate.impl.SessionImpl.fireDelete(SessionImpl.java:766)rn org.hibernate.impl.SessionImpl.delete(SessionImpl.java:744)rn org.springframework.orm.hibernate3.HibernateTemplate$25.doInHibernate(HibernateTemplate.java:852)rn org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:419)rn org.springframework.orm.hibernate3.HibernateTemplate.executeWithNativeSession(HibernateTemplate.java:374)rn org.springframework.orm.hibernate3.HibernateTemplate.delete(HibernateTemplate.java:846)rn org.springframework.orm.hibernate3.HibernateTemplate.delete(HibernateTemplate.java:842)rn com.dao.SubjectDAO.delete(SubjectDAO.java:57)rn com.biz.SubjectBiz.deleteSubject(SubjectBiz.java:75)rn这是什么情况啊,有没有大侠知道,指点一下.
Unknown error 1146的解决办法:
在mybatis与springboot整合的项目里面,报如下错误:2018-06-03 15:16:50.148 ERROR 20777 --- [-nio-80-exec-16] o.s.boot.web.support.ErrorPageFilter : Forwarding to error page from request [/blogfirst] due to exceptio...
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown column 'this_
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown column 'this_.flowId' in 'field list'rn at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)rn at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)rn at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)rn at java.lang.reflect.Constructor.newInstance(Constructor.java:526)rn at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)rn at com.mysql.jdbc.Util.getInstance(Util.java:381)rn at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1030)rn at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:956)rn at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3491)rn at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3423)rn
java.lang.IllegalArgumentException: Unknown URI content:
复制源项目program1,粘贴更名为program2。rn更改AndroidManifest.xml:rn program1中rnrn program2中rnrn当program1和program2安装在同一个模拟器中运行时,出错了:rnrn04-18 01:34:36.591: E/DatabaseUtils(833): Writing exception to parcelrn04-18 01:34:36.591: E/DatabaseUtils(833): java.lang.IllegalArgumentException: Unknown URI content://com.coperator.db/accountsrn04-18 01:34:36.591: E/DatabaseUtils(833): at com.coperator.db.DBProvider.delete(DBProvider.java:286)rn04-18 01:34:36.591: E/DatabaseUtils(833): at android.content.ContentProvider$Transport.delete(ContentProvider.java:222)rn04-18 01:34:36.591: E/DatabaseUtils(833): at android.content.ContentProviderNative.onTransact(ContentProviderNative.java:186)rn04-18 01:34:36.591: E/DatabaseUtils(833): at android.os.Binder.execTransact(Binder.java:320)rn04-18 01:34:36.591: E/DatabaseUtils(833): at dalvik.system.NativeStart.run(Native Method)rnrn忘高手给点指示和解决的方法,谢谢!!!
k8s- unknown问题排查
一、问题描述 kubernetes pod NodeLost 分析 环境 系统: centOS7 k8s 1 master, 2 node IP k8s master 176 k8s node 175 k8s node 176 kubelet、kube-proxy、kube-dns直接安装在linux系统上 问题 卸载监控时,一直一些组件未删除(正常是所有相关组...
hibernate5.0.6报错Unknown entity
网上这个错误的解决方法很多,我都试过了但是没有一个行的,确认我的配置文件没写错,请问是什么问题?rn**报错**rnException in thread "main" org.hibernate.MappingException: Unknown entity: com.hibernate.Studentrn at org.hibernate.internal.SessionFactoryImpl.getEntityPersister(SessionFactoryImpl.java:781)rn at org.hibernate.internal.SessionImpl.getEntityPersister(SessionImpl.java:1520)rn at org.hibernate.event.internal.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:100)rn at org.hibernate.event.internal.DefaultSaveOrUpdateEventListener.saveWithGeneratedOrRequestedId(DefaultSaveOrUpdateEventListener.java:192)rn at org.hibernate.event.internal.DefaultSaveEventListener.saveWithGeneratedOrRequestedId(DefaultSaveEventListener.java:38)rn at org.hibernate.event.internal.DefaultSaveOrUpdateEventListener.entityIsTransient(DefaultSaveOrUpdateEventListener.java:177)rn at org.hibernate.event.internal.DefaultSaveEventListener.performSaveOrUpdate(DefaultSaveEventListener.java:32)rn at org.hibernate.event.internal.DefaultSaveOrUpdateEventListener.onSaveOrUpdate(DefaultSaveOrUpdateEventListener.java:73)rn at org.hibernate.internal.SessionImpl.fireSave(SessionImpl.java:679)rn at org.hibernate.internal.SessionImpl.save(SessionImpl.java:671)rn at org.hibernate.internal.SessionImpl.save(SessionImpl.java:666)rn at com.hibernateservice.StudentTest.main(StudentTest.java:33)rn**hibernate.cfg.xml:**rn```rn rnrnrn rn com.mysql.jdbc.Driverrn 1234rn jdbc:mysql://localhost:3306/hibernatern rootrn rn org.hibernate.dialect.MySQL5Dialectrn truern updatern rn rnrn```rn**Student.hbm.xml**rnrnrn```rn rnrnrnrn rn rn rn rn rn rnrnrn```rn**Student.java:**rnrnrn```rn package com.hibernate;rnrnpublic class Student rnrn int id;rn String name;rn rn /**rn * @return the idrn */rn public long getId() rn return id;rn rnrn /**rn * @param id the id to setrn */rn public void setId(int id) rn this.id = id;rn rnrn /**rn * @return the namern */rn public String getName() rn return name;rn rnrn /**rn * @param name the name to setrn */rn public void setName(String name) rn this.name = name;rn rn rn public Student() rn // TODO Auto-generated constructor stubrnrn rnrnrnrn```rn**StudentTest.java:**rnrnrn```rn package com.hibernateservice;rnimport com.hibernate.Student;rnimport org.hibernate.Session;rnimport org.hibernate.SessionFactory;rnimport org.hibernate.boot.registry.StandardServiceRegistryBuilder;rnimport org.hibernate.cfg.Configuration;rnrnpublic class StudentTest rnrn public StudentTest() rn // TODO Auto-generated constructor stubrn rn rn public static void main(String[] args) rn rn Configuration config = new Configuration().configure();rn rn org.hibernate.service.ServiceRegistry registry = rn new StandardServiceRegistryBuilder().applySettings(config.getProperties()).build();rn rn SessionFactory sessionFactory = config.buildSessionFactory(registry);rn Session session = sessionFactory.openSession();rn session.beginTransaction();rn rn Student s = new Student();rn s.setName("张三");rn s.setId(0);rn session.save(s);rn rn session.getTransaction().commit();rn session.close();rn sessionFactory.close();rn rnrnrnrn```rn**目录:**rn![图片说明](https://img-ask.csdn.net/upload/201512/23/1450800820_219127.png)rnrnrnrn
spb constant unknown
我用BCB6里面的IBBackupService控件写了个数据库备份的程序.rn不过,当我设置:Active = true的时候,就会出现如下的错误信息:rnrnspb constant unknownrnrn搞不清楚是怎么回事, 请高手指教.rn
Unknown tag (s:textfiled)
struts2 的一个登陆界面代码[code=Java][/code]rn<%@ page language="java" contentType="text/html; charset=utf-8" %>rnrn<%@ taglib prefix="s" uri="/struts-tags"%>rn rnrn rn 登录页面rn rn rn rn rn rn rn rn rn
【求助】'PETHREAD' : unknown size
为什么会这样呢? 新手刚学。网上都没有搜索得到。 rn已经包含了 ntddk.h
unknown column field list
[code=PHP]rnif (empty($username)) $error[]='Username cannot be empty.';rn$query='select user_name from user where user_name="' . $username . '"';rn$result=mysql_query($query) or die(mysql_error($db));rnif (mysql_num_rows($result)>0) $error[]='Username has already been used.'; $username='';rn[/code]rn这个是我的代码,出错信息:Unknown column 'tchen13' in 'field list'rntchen13是我post过来的变量rn
[求助]Unknown Certificates
我们正在开发J2ME的应用,使用到了https。rnrn在登陆未知的https网站的时候,报错:rnrnCertificate was issued by an unrecognized entityrnrn我知道这是sun说的Example 2: Unknown Certificates rnrnhttp://wireless.java.sun.com/midp/articles/https/rnrn可是我又不可能改动需要访问网站的任何设置,我该怎么做呢?
问题:unknown character '0xa1'
#include rnvoid main()rnrnint x=-1;rn  do x=x*x;rn while(!x);rnrn在 vc6中提示如题的错误,这是为什么呀?
优盘unknown driver 问题
kingston 2G 优盘 插上时是安装成功可以使用了,但过一会就是unknown driver 然后就没反应了,在我的电脑里也没有显示,在任务栏也没有显示,这种情况算什么,请高手帮忙
求助struts-default.xml - [unknown location]
小弟新手 ,重新装了系统,请各位高手 帮忙看看是什么问题rn载入工作空间之后启动服务器就会报错:rnUnable to load configuration. - [unknown location]rn at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:58)rn at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:360)rn at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:403)rn at org.apache.struts2.dispatcher.FilterDispatcher.init(FilterDispatcher.java:190)rn at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:275)rn at org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:397)rn at org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:108)rn at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3693)rn at org.apache.catalina.core.StandardContext.start(StandardContext.java:4340)rn at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)rn at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)rn at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)rn at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:920)rn at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:883)rn at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:492)rn at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138)rn at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)rn at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)rn at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)rn at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)rn at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)rn at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)rn at org.apache.catalina.core.StandardService.start(StandardService.java:516)rn at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)rn at org.apache.catalina.startup.Catalina.start(Catalina.java:566)rn at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)rn at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)rn at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)rn at java.lang.reflect.Method.invoke(Unknown Source)rn at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)rn at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)rnCaused by: Caught exception while loading file struts-default.xml - [unknown location]rn at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.loadConfigurationFiles(XmlConfigurationProvider.java:894)rn at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.loadDocuments(XmlConfigurationProvider.java:144)rn at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.init(XmlConfigurationProvider.java:111)rn at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:164)rn at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:55)rn ... 30 morernCaused by: java.lang.ClassCastException: org.apache.xerces.parsers.XML11Configuration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfigurationrn at org.apache.xerces.parsers.DOMParser.(Unknown Source)rn at org.apache.xerces.parsers.DOMParser.(Unknown Source)rn at org.apache.xerces.jaxp.DocumentBuilderImpl.(Unknown Source)rn at org.apache.xerces.jaxp.DocumentBuilderFactoryImpl.newDocumentBuilder(Unknown Source)rn at com.sun.org.apache.xalan.internal.xsltc.trax.SAX2DOM.(Unknown Source)rn at com.sun.org.apache.xalan.internal.xsltc.runtime.output.TransletOutputHandlerFactory.getSerializationHandler(Unknown Source)rn at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.getOutputHandler(Unknown Source)rn at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerHandlerImpl.setResult(Unknown Source)rn at com.opensymphony.xwork2.util.DomHelper$DOMBuilder.setup(DomHelper.java:205)rn at com.opensymphony.xwork2.util.DomHelper$DOMBuilder.(DomHelper.java:190)rn at com.opensymphony.xwork2.util.DomHelper$DOMBuilder.(DomHelper.java:181)rn at com.opensymphony.xwork2.util.DomHelper$DOMBuilder.(DomHelper.java:167)rn at com.opensymphony.xwork2.util.DomHelper.parse(DomHelper.java:107)rn at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.loadConfigurationFiles(XmlConfigurationProvider.java:885)rn ... 34 morern2010-6-11 9:52:59 org.apache.catalina.core.StandardContext start
Content-Disposition和Application/unknown从哪里能查到的
Page.Response.ContentType="Application/unknown";rnResponse.AddHeader("Content-Disposition","attachment; filename=" +rn ds.Tables[0].Rows[0]["filename"].ToString() + ";");rn中的Content-Disposition和Application/unknown从哪里能查到的,查找时的关键字是什么?rnrn先谢谢了!
Unknown system variable 'storage_engine'
Jira6不支持mysql5.7,需要此jar,具体就是报错 Unknown system variable 'storage_engine' 的解决
java.lang.NullPointerException at java.applet.Applet.getCodeBase(Unknown Source)
代码如下:小弟初来此地,请各位大虾多指教。rnrnrnrnimport java.net.*;rnimport java.applet.*;rnrnpublic class URLtestrnrn public static void main(String args[])rn rn Applet nice=null;rn tryrn rn nice=new Applet();rn rn catch(Exception e)rn rn System.out.println("exception ");rn rn URL url_1=null;rn if(nice==null)rn rn System.out.println("nice is null");rn rn elsern rn System.out.println("nice is not null");rn url_1=nice.getCodeBase();rn if(url_1==null)rn rn System.out.println("url_1 is null");rn rn elsern rn System.out.println("url_1 is not null");rn System.out.println(url_1);rn rn //System.out.println(nice.getCodeBase().toString());rn rn //System.out.println("nice");rn rn
Unknown entity异常
org.springframework.orm.hibernate3.HibernateSystemException: Unknown entity: com.lvxf.entity.AskTry; nested exception is org.hibernate.MappingException: Unknown entity: com.lvxf.entity.AskTry org.springframework.orm.hibernate3.SessionFactoryUtils.convertHibernateAccessException(SessionFactoryUtils.java:690) org.springframework.orm.hibernate3.HibernateAccessor.convertHibernateAccessException(HibernateAccessor.java:412) org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:411) org.springframework.orm.hibernate3.HibernateTemplate.executeWithNativeSession(HibernateTemplate.java:374) org.springframework.orm.hibernate3.HibernateTemplate.save(HibernateTemplate.java:683)rncom.lvxf.dao.AskTryDao.save(AskTryDao.java:11)rncom.lvxf.biz.AskTryBiz.save(AskTryBiz.java:17)rncom.lvxf.action.AskTryAction.doAskTry(AskTryAction.java:125)rnsun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)rnsun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)rnsun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)rnjava.lang.reflect.Method.invoke(Method.java:606)rncom.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActionInvocation.java:446) com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultActionInvocation.java:285) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248) org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept(DebuggingInterceptor.java:256) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:176) com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:265) org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:68) com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(ConversionErrorInterceptor.java:138) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:238) com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:238) com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:191) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) org.apache.struts2.interceptor.MultiselectInterceptor.intercept(MultiselectInterceptor.java:73) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:91) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:252) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept(ModelDrivenInterceptor.java:100) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept(ScopedModelDrivenInterceptor.java:141) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept(ChainingInterceptor.java:145) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.interceptor.PrepareInterceptor.doIntercept(PrepareInterceptor.java:171) com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.interceptor.I18nInterceptor.intercept(I18nInterceptor.java:176) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) org.apache.struts2.interceptor.ServletConfigInterceptor.intercept(ServletConfigInterceptor.java:164) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.interceptor.AliasInterceptor.intercept(AliasInterceptor.java:193) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor.intercept(ExceptionMappingInterceptor.java:187)rncom.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:242) org.apache.struts2.impl.StrutsActionProxy.execute(StrutsActionProxy.java:54)rnorg.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:544)rnorg.apache.struts2.dispatcher.ng.ExecuteOperations.executeAction(ExecuteOperations.java:77) org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:91)rnrnroot causernrnorg.hibernate.MappingException: Unknown entity: com.lvxf.entity.AskTryrnorg.hibernate.impl.SessionFactoryImpl.getEntityPersister(SessionFactoryImpl.java:628)rnorg.hibernate.impl.SessionImpl.getEntityPersister(SessionImpl.java:1366)rnorg.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:121) org.hibernate.event.def.DefaultSaveOrUpdateEventListener.saveWithGeneratedOrRequestedId(DefaultSaveOrUpdateEventListener.java:210) org.hibernate.event.def.DefaultSaveEventListener.saveWithGeneratedOrRequestedId(DefaultSaveEventListener.java:56) org.hibernate.event.def.DefaultSaveOrUpdateEventListener.entityIsTransient(DefaultSaveOrUpdateEventListener.java:195) org.hibernate.event.def.DefaultSaveEventListener.performSaveOrUpdate(DefaultSaveEventListener.java:50) org.hibernate.event.def.DefaultSaveOrUpdateEventListener.onSaveOrUpdate(DefaultSaveOrUpdateEventListener.java:93)rnorg.hibernate.impl.SessionImpl.fireSave(SessionImpl.java:563)rnorg.hibernate.impl.SessionImpl.save(SessionImpl.java:551)rnorg.hibernate.impl.SessionImpl.save(SessionImpl.java:547) org.springframework.orm.hibernate3.HibernateTemplate$12.doInHibernate(HibernateTemplate.java:686) org.springframework.orm.hibernate3.HibernateTemplate$12.doInHibernate(HibernateTemplate.java:1) org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:406)rnorg.springframework.orm.hibernate3.HibernateTemplate.executeWithNativeSession(HibernateTemplate.java:374)rnorg.springframework.orm.hibernate3.HibernateTemplate.save(HibernateTemplate.java:683)rncom.lvxf.dao.AskTryDao.save(AskTryDao.java:11)rncom.lvxf.biz.AskTryBiz.save(AskTryBiz.java:17)rncom.lvxf.action.AskTryAction.doAskTry(AskTryAction.java:125)rnsun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)rnsun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)rnsun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)rnjava.lang.reflect.Method.invoke(Method.java:606) com.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActionInvocation.java:446) com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultActionInvocation.java:285) com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn。。。。。。rnAskTryDao.java中:rnpublic class AskTryDao extends HibernateDaoSupportrnpublic void save(AskTry s)rnsuper.getHibernateTemplate().save(s);rnrnrnAskTryBiz.java处理业务逻辑rnAskTry.java中用注解,控制反转是这么写的:rn@Entityrn@Table(name = "asktry")rnpublic class AskTry rnprivate String compName;rnprivate String ......rn@Idrn@GeneratedValue(generator = "gen")rn@GenericGenerator(name = "gen", strategy = "native", parameters = @Parameter(name = "unsaved-value", value = "0"), )rn@Column(name = "compName", nullable = true, length = 50)rnpublic String getCompName() rnreturn compName;rnrn ......rnapplicationContext.xml中:rnrn rn com.mysql.jdbc.Driverrn rn rn jdbc:mysql://localhost:3306/lvxfrn rn rn lvxfrn rn rn 123456rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn提交时页面500了,请求指点!
unknown error 0x800a0c93
请教一下,用ado 方式向sql server2000的数据库中的表rn写完数据后,就产生rnunknown error 0x800a0c93rn请教一下,这个是为什么?rn数据可以正确写入..rn谢谢了、
这么多Unknown Source
Android程序运行时下面Console上出现:rn[2010-10-18 22:42:42 - ddms]nullrnjava.lang.NullPointerExceptionrn at com.android.ddmlib.JdwpPacket.writeAndConsume(Unknown Source)rn at com.android.ddmlib.Client.sendAndConsume(Unknown Source)rn at com.android.ddmlib.HandleHello.sendHELO(Unknown Source)rn at com.android.ddmlib.HandleHello.sendHelloCommands(Unknown Source)rn at com.android.ddmlib.Client.getJdwpPacket(Unknown Source)rn at com.android.ddmlib.MonitorThread.processClientActivity(Unknown Source)rn at com.android.ddmlib.MonitorThread.run(Unknown Source)rnrnrn是怎么回事??rn
unknown partition table
在看《linux设备驱动程序》(第3版)的块设备驱动的编写的时候,在板子上测试sbull.c程序,编译可以通过,insmod sbull.ko的时候提示sbulla: unknown partition table,这个是什么原因引起的?
unknown error 0x800A0E78
CoInitialize(NULL);rn _ConnectionPtr pConn(__uuidof(Connection));rn _RecordsetPtr pRst(__uuidof(Recordset));rn _CommandPtr pCmd(__uuidof(Command));rn rn pConn->ConnectionString="Provider=SQLOLEDB.1;Password=123;Persist Security Info=True;User ID=sa;Initial Catalog=patient";rn pConn->Open("","","",adConnectUnspecified);rn rn rn pCmd->put_ActiveConnection(_variant_t((IDispatch*)pConn));rn //pCmd->CommandText="create table p1001200902271205 (i float,x float,y float)";rn //pRst=pCmd->Execute(NULL,NULL,adCmdText);rn rnrnrn for(int i=0;i<=pnum;i++)rn rn char Buffer[30]="";rn char comma[2]=",";rn char sql[100]="insert into p20090226 values(";rn itoa(i,Buffer,10);rn strcat(sql,Buffer);rn strcat(sql,comma);rn int y=size*sin((float)i/size);rn point.x=m+i;rn point.y=n-y;rn itoa(point.x,Buffer,10);rn strcat(sql,Buffer);rn strcat(sql,comma);rn itoa(point.y,Buffer,10);rn strcat(sql,Buffer);rn char end[20]=")";rn strcat(sql,end);rn pCmd->CommandText= (_bstr_t)sql;rn pRst=pCmd->Execute(NULL,NULL,adCmdText);rn pDC->LineTo(point);rn pDC->MoveTo(point);rn rn pRst->Close();rn pConn->Close();rn pCmd.Release();rn pRst.Release();rn pConn.Release();rn CoUninitialize();rn运行后插入成功了 但是在运行到pRst->Close();后报了unknown error 0x800A0E78错 我不知道是如何引起的 希望高手帮忙看下 如何修改
再问: SPB constant unknown
我用BCB6里面的IBBackupService控件写了个数据库备份的程序. rn不过,当我设置:Active = true的时候,就会出现如下的错误信息: rn rnspb constant unknown rn rn搞不清楚是怎么回事, 请高手指教. rn
Jlink调试unknown device
新焊接好的一块S3C2442板子接上JLINK,插上电。JLINK上显示如下rn[img=http://img.my.csdn.net/uploads/201304/07/1365326714_2336.jpg][/img]rnrn输入r 一般都是rn****Error:Unable to halt ARM core 如下信息rn[img=http://img.my.csdn.net/uploads/201304/07/1365326896_5552.jpg][/img]rnrn各电压都正常。
求教异常:org.codehaus.xfire.fault.XFireFault: unknown
以下是全部异常信息,帮帮忙吧 各位大侠rn严重: Servlet.service() for servlet action threw exceptionrnorg.codehaus.xfire.fault.XFireFault: unknownrn at org.codehaus.xfire.fault.Soap11FaultSerializer.readMessage(Soap11FaultSerializer.java:31)rn at org.codehaus.xfire.fault.SoapFaultSerializer.readMessage(SoapFaultSerializer.java:28)rn at org.codehaus.xfire.soap.handler.ReadHeadersHandler.checkForFault(ReadHeadersHandler.java:111)rn at org.codehaus.xfire.soap.handler.ReadHeadersHandler.invoke(ReadHeadersHandler.java:67)rn at org.codehaus.xfire.handler.HandlerPipeline.invoke(HandlerPipeline.java:131)rn at org.codehaus.xfire.client.Client.onReceive(Client.java:406)rn at org.codehaus.xfire.transport.http.HttpChannel.sendViaClient(HttpChannel.java:139)rn at org.codehaus.xfire.transport.http.HttpChannel.send(HttpChannel.java:48)rn at org.codehaus.xfire.handler.OutMessageSender.invoke(OutMessageSender.java:26)rn at org.codehaus.xfire.handler.HandlerPipeline.invoke(HandlerPipeline.java:131)rn at org.codehaus.xfire.client.Invocation.invoke(Invocation.java:79)rn at org.codehaus.xfire.client.Invocation.invoke(Invocation.java:114)rn at org.codehaus.xfire.client.Client.invoke(Client.java:336)rn at org.codehaus.xfire.client.XFireProxy.handleRequest(XFireProxy.java:77)rn at org.codehaus.xfire.client.XFireProxy.invoke(XFireProxy.java:57)rn at $Proxy195.smsSend(Unknown Source)rn at com.thtf.ezsrs.city.util.telservice.service.spring.CallWS.smsSend(CallWS.java:179)rn at com.thtf.ezsrs.city.util.telservice.web.action.MessAction.doExecute(MessAction.java:48)rn at com.thtf.ezone.ezframework.adapter.struts.ActionUtil.execute(ActionUtil.java:306)rn at com.thtf.ezone.ezframework.adapter.struts.FWAction.execute(FWAction.java:176)rn at com.thtf.ezone.ezframework.adapter.struts.FWRequestProcessor.processActionPerform(FWRequestProcessor.java:70)rn at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:224)rn at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1194)rn at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414)rn at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)rn at com.thtf.ezone.ezframework.servlet.FrontController.service(FrontController.java:123)rn at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)rn at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)rn at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)rn at com.thtf.ezsrs.city.util.permiss.filter.LoginFilter.doFilter(LoginFilter.java:58)rn at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)rn at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)rn at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)rn at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)rn at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)rn at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)rn at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)rn at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)rn at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:857)rn at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588)rn at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)rn at java.lang.Thread.run(Thread.java:619)rn
Unknown format version: -9
11/4/11 10:07:23 AM CST: [INFO] User settings file does not exist C:\Documents and Settings\Administrator\.m2\settings.xmlrn[color=#FF0000]11/4/11 10:07:23 AM CST: Error on adding indexing context central; Unknown format version: -9[/color]rn11/4/11 10:07:24 AM CST: [INFO] User settings file does not exist C:\Documents and Settings\Administrator\.m2\settings.xmlrnrn什么意思?
NHibernate Unknown entity class?
配置文件(我用的sql2008)rn[code=XML]rn rn rn rn rn rn rnrn rn rn rn rn rn rn rn rn rn[/code]rnrn[code=C#]rnrn if (factory == null)rn rn Configuration cfg = new Configuration();rn string connectionStringName = cfg.Properties["connectionStringName"].ToString();rn cfg.Properties.Add("hibernate.connection.connection_string", System.Configuration.ConfigurationManager.ConnectionStrings[connectionStringName].ConnectionString);rn cfg.AddAssembly("NHibernate.Factory");//rn rn factory = cfg.BuildSessionFactory();rn logger = LogManager.GetLogger("HibernateDAL");rn rnrnrnrnrnusing (ISession session = factory.OpenSession())rn rn using (ITransaction transaction = session.BeginTransaction())rn rn tryrn rn session.SaveOrUpdate(model);//[color=#FF0000]出现错误:Unknown entity class[/color]rn transaction.Commit();rn rn catch (Exception ex)rn rn transaction.Rollback();rn logger.Error("插入model时失败:" + model, ex);rn rn rn rnrn[/code]rnrnrn
preg_replace()Unknown modifier 'p'
$url_query=preg_replace("^|&page=$page","",$url_query);rn这个应该怎么修改才不报错呢?rnWarning: preg_replace() [function.preg-replace]: Unknown modifier 'p' in D:\wamp\www\spbs\common\page.class.php on line 40
org.springframework.orm.hibernate3.HibernateSystemException: Unknown entity: Use
小弟初学ssh2,配置一则User的增删查改实例,遇到如下问题,求高手解决:rnexception rnorg.springframework.orm.hibernate3.HibernateSystemException: Unknown entity: User; nested exception is org.hibernate.MappingException: Unknown entity: Userrn org.springframework.orm.hibernate3.SessionFactoryUtils.convertHibernateAccessException(SessionFactoryUtils.java:679)rn org.springframework.orm.hibernate3.HibernateAccessor.convertHibernateAccessException(HibernateAccessor.java:412)rn org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:411)rn org.springframework.orm.hibernate3.HibernateTemplate.executeWithNativeSession(HibernateTemplate.java:374)rn org.springframework.orm.hibernate3.HibernateTemplate.get(HibernateTemplate.java:532)rn org.springframework.orm.hibernate3.HibernateTemplate.get(HibernateTemplate.java:526)rn com.tribesoft.dao.UserDAO.findById(UserDAO.java:64)rn com.tribesoft.service.UserService.updateUser(UserService.java:31)rn com.tribesoft.action.UserAction.updateUser(UserAction.java:76)rn sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)rn sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)rn sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)rn java.lang.reflect.Method.invoke(Unknown Source)rn com.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActionInvocation.java:452)rn com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultActionInvocation.java:291)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:254)rn com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:176)rn com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:263)rn org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:68)rn com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(ConversionErrorInterceptor.java:133)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:207)rn com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:207)rn com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:190)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn org.apache.struts2.interceptor.MultiselectInterceptor.intercept(MultiselectInterceptor.java:75)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:94)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:243)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept(ModelDrivenInterceptor.java:100)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept(ScopedModelDrivenInterceptor.java:141)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept(DebuggingInterceptor.java:267)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept(ChainingInterceptor.java:142)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn com.opensymphony.xwork2.interceptor.PrepareInterceptor.doIntercept(PrepareInterceptor.java:166)rn com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn com.opensymphony.xwork2.interceptor.I18nInterceptor.intercept(I18nInterceptor.java:176)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn org.apache.struts2.interceptor.ServletConfigInterceptor.intercept(ServletConfigInterceptor.java:164)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn com.opensymphony.xwork2.interceptor.AliasInterceptor.intercept(AliasInterceptor.java:190)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor.intercept(ExceptionMappingInterceptor.java:187)rn com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)rn org.apache.struts2.impl.StrutsActionProxy.execute(StrutsActionProxy.java:52)rn org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:485)rn org.apache.struts2.dispatcher.ng.ExecuteOperations.executeAction(ExecuteOperations.java:77)rn org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:91)rnrnroot cause rnorg.hibernate.MappingException: Unknown entity: Userrn org.hibernate.impl.SessionFactoryImpl.getEntityPersister(SessionFactoryImpl.java:628)rn org.hibernate.event.def.DefaultLoadEventListener.onLoad(DefaultLoadEventListener.java:91)rn org.hibernate.impl.SessionImpl.fireLoad(SessionImpl.java:906)rn org.hibernate.impl.SessionImpl.get(SessionImpl.java:843)rn org.springframework.orm.hibernate3.HibernateTemplate$2.doInHibernate(HibernateTemplate.java:538)rn org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:406)rn org.springframework.orm.hibernate3.HibernateTemplate.
org.hibernate.MappingException: Unknown entity的问题
在hibernate下,数据DAO里写User instance = (SystemUser) session.get("User", id);rn会报错org.hibernate.MappingException: Unknown entity Userrn而给User加上包名,写成User instance = (SystemUser) session.get("com.test.User", id);就可以,这个是怎么原因?带上包名很麻烦的,有没有什么配置方法?rn
Sys.WebForms.PageRequestManagerServerErrorException.An unknown error occurred ..
最近我发现我的updataPanel用起来好像有问题。rn于是我做了测试程序测试了下。测试程序如下:rn[code=C#]rnrn rn rn rn rn rn <%=DateTime .Now %>rn rn rn rn rn rn rn <%=DateTime .Now %>rn rn rnrn[/code]rnWinconfig保证没问题的~rnrn我一点那个BUTTON就弹出这个错误:Sys.WebForms.PageRequestManagerServerErrorException.An unknown error occurred while processing the request on the server.The status code returned from the server was:404rnrn请各位帮帮我
Unknown tag (c:out).
如题,怎样解决啊?
unknown directive "ngx_http_access_module"
之前,我是没有启用--with-http_sub_module,所以报unknown directive "ngx_http_access_module",是可以理解.rn我是这么想的.但是,我重新编译了.并显示有这个,如下:rn./nginx -V:rnconfigure arguments: --with-http_stub_status_module --with-http_sub_modulernrn配置文件中加rnngx_http_access_module rn include blocksip.conf;rnrn还是出现rnunknown directive "ngx_http_access_module"rnrn哪位知道这是怎么回事?
相关热词 c# gdi 占用内存 c#中遍历字典 c#控制台模拟dos c# 斜率 最小二乘法 c#进程延迟 c# mysql完整项目 c# grid 总行数 c# web浏览器插件 c# xml 生成xsd c# 操作sql视图