- 博客(36)
- 资源 (18)
- 收藏
- 关注
原创 spring中对hibernate的支持
源自:JavaFeng (个人网站) spring中对hibernate的支持是非常强大的,从一个简单的例子就看得出来,从这个例子中我们还将对所谓的轻量级容器做一些讨论。 首先需要配置数据源,通常我们有两种方式获得Connection,一是自己编写代码获得连接,二是从JNDI环境中得到DataSource,然后产生一个Connection。无论怎样,既然是spring下面的对象,就应该注册到
2007-06-30 13:51:00 961
spring中对hibernate的支持
源自:JavaFeng(个人网站)spring中对hibernate的支持是非常强大的,从一个简单的例子就看得出来,从这个例子中我们还将对所谓的轻量级容器做一些讨论。 首先需要配置数据源,通常我们有两种方式获得Connection,一是自己编写代码获得连接,二是从JNDI环境中得到DataSource,然后产生一个Connection。无论怎样,既然是spring下面的对象,就应该注册到配置...
2007-06-30 13:51:00 402 1
转载 讨论:写程序到底需不需要懂数学?
写程序到底需不需要懂数学?数学对于程序设计师来说到底重不重要?!类似这样标题的讨论,在网络上已经不知道被讨论多少次了。研究所顺利考上的向往已久的资工所,成为名符其实的本科系学生,本以为可以不用再玩数学了,但我发现我错了,是不用再玩那些抽久的高等数学没错,但线性代数、机率统计、离散数学等…用了更多的数学,我想不出来有哪门资工研究所的课没用到数学的。而且你最后的硕士论文要写出来,数学更是不能少
2007-06-28 20:02:00 650
讨论:写程序到底需不需要懂数学?
写程序到底需不需要懂数学?数学对于程序设计师来说到底重不重要?!类似这样标题的讨论,在网络上已经不知道被讨论多少次了。研究所顺利考上的向往已久的资工所,成为名符其实的本科系学生,本以为可以不用再玩数学了,但我发现我错了,是不用再玩那些抽久的高等数学没错,但线性代数、机率统计、离散数学等…用了更多的数学,我想不出来有哪门资工研究所的课没用到数学的。而且你最后的硕士论文要写出来,数学更是不能少...
2007-06-28 20:02:00 52
原创 Python之父Guido van Rossum专题访谈
Python 语言是最流行的编程语言之一,无论在 Web 应用还是非 Web 应用中均扮演者重要角色。Python 语言之父为大家介绍 Python 语言的设计理念,应用技巧和适用范围,并解析 Python 语言的发展前景。主讲人 Guido van Rossum 是 Python 语言的发明人,于 2005 年加入 Google。他领导并从事 Python 语言每一个版本的设计和开发工作
2007-06-28 15:51:00 2569
Python之父Guido van Rossum专题访谈
Python 语言是最流行的编程语言之一,无论在 Web 应用还是非 Web 应用中均扮演者重要角色。Python 语言之父为大家介绍 Python 语言的设计理念,应用技巧和适用范围,并解析 Python 语言的发展前景。主讲人 Guido van Rossum 是 Python 语言的发明人,于 2005 年加入 Google。他领导并从事 Python 语言每一个版本的设计和开发工作...
2007-06-28 15:51:00 1244
翻译 Programming Microsoft Internet Explore 5(五)
第5章 创建ActiveX控件 当你在做web应用程序时,假设你想在网页中包含很复杂的功能,使用基于web页的DHTML和Script语言就无能为力了.例如,你想访问某个客户端计算机的信息,如你想打开或是写入一个文件,或者你想限制Intenet用户访问某些站点.也许你想阻止用户访问某些游戏站点等. 为了实现这个目标,你需要创建你自己的应用程序来取得浏览器控制
2007-06-26 21:20:00 717
Programming Microsoft Internet Explore 5(五)
第5章 创建ActiveX控件 当你在做web应用程序时,假设你想在网页中包含很复杂的功能,使用基于web页的DHTML和Script语言就无能为力了.例如,你想访问某个客户端计算机的信息,如你想打开或是写入一个文件,或者你想限制Intenet用户访问某些站点.也许你想阻止用户访问某些游戏站点等. 为了实现这个目标,你需要创建你自己的应用程序来取得浏览器控制权(下一章介绍).使用微软的Ac...
2007-06-26 21:20:00 120
转载 成年人必看的5个故事
1、 情况不同 一只小猪、一只绵羊和一头乳牛,被关在同一个畜栏里。有一次,牧人捉住小猪,牠大声嚎叫,猛烈地抗拒。绵羊和乳牛讨厌牠的嚎叫,便说:「他常常捉我们,我们并不大呼小叫。小猪听了回答道:「捉你们和捉我完全是两回事,他捉你们,只是要你们的毛和乳汁,但是捉住我,却是要我的命呢! 立场不同、所处环境不同的人,很难了解对方的感受;因此对别人的失意、挫折、伤痛,不宜幸灾乐祸,而应要有关怀、了解的心
2007-06-26 12:53:00 641
成年人必看的5个故事
1、 情况不同 一只小猪、一只绵羊和一头乳牛,被关在同一个畜栏里。有一次,牧人捉住小猪,牠大声嚎叫,猛烈地抗拒。绵羊和乳牛讨厌牠的嚎叫,便说:「他常常捉我们,我们并不大呼小叫。小猪听了回答道:「捉你们和捉我完全是两回事,他捉你们,只是要你们的毛和乳汁,但是捉住我,却是要我的命呢! 立场不同、所处环境不同的人,很难了解对方的感受;因此对别人的失意、挫折、伤痛,不宜幸灾乐祸,而应要有关怀、了解的心...
2007-06-26 12:53:00 58
原创 Oracle约束介绍
Oracle数据库约束 分为以下几种:1:not null和check约束2.PK主键约束3.Unique唯一值约束4.FK外键约束下面介绍了以上4种约束的创建,添加,删除方法:1.check约束当创建约束时,系统会自动给约束取名,也可用户自己取名>SQL create table person(id int, sex varchar2(50)) constrain
2007-06-24 13:32:00 1308
Oracle约束介绍
Oracle数据库约束分为以下几种:1:not null和check约束2.PK主键约束3.Unique唯一值约束4.FK外键约束下面介绍了以上4种约束的创建,添加,删除方法:1.check约束当创建约束时,系统会自动给约束取名,也可用户自己取名>SQL create table person(id int, sex varchar2(50)) constra...
2007-06-24 13:32:00 84
原创 oracle分组统计
我们假定有如下员工信息表:TableName:DEPARTMENTid depno sex name 1 1 0 Lily 2 2 1 Tom 3 1 1 Jim 4 1 0 Kite 5
2007-06-24 12:29:00 1785
oracle分组统计
我们假定有如下员工信息表:TableName:DEPARTMENTid depno sex name1 10 Lily2 2 1 Tom31 1 Jim4 1 0 Kite5 2 1 Green6 1 1 Mr.Right7 2 1 Boss问题:1.每个部门的男女各自总人数2.总的员工数及每个部门的总人数分析:略...答案:1.se...
2007-06-24 12:29:00 166
原创 oracle函数
1.to_date(date,format)功能:将date日期字符串类型按format格式,转换成DATE类型如:select to_date(2005-03-23,yyyy-mm-dd) from dual;2.to_char(x[,format])功能:将x按format转换成字符串类型如:select to_char(sysdate,yyyy-MM-dd HH
2007-06-24 12:15:00 704
oracle函数
1.to_date(date,format)功能:将date日期字符串类型按format格式,转换成DATE类型如:select to_date('2005-03-23','yyyy-mm-dd') from dual;2.to_char(x[,format])功能:将x按format转换成字符串类型如:select to_char(sysdate,'yyyy-MM-dd HH...
2007-06-24 12:15:00 60
原创 Oracle的SYS密码找回方法
有两种方法找回sys密码:1.用windows验证(请确认OracleBaseDir/ora92/network/admin/sqlnet.ora文件中,SQLNET.AUTHENTICATION_SERVICES= (NTS)这行未被注释),然后敲入sql> connect sys/随意密码 as sysdba;sql> alter user sys identified
2007-06-24 11:47:00 1722
Oracle的SYS密码找回方法
有两种方法找回sys密码:1.用windows验证(请确认OracleBaseDir/ora92/network/admin/sqlnet.ora文件中,SQLNET.AUTHENTICATION_SERVICES= (NTS)这行未被注释),然后敲入sql> connect sys/随意密码 as sysdba;sql> alter user sys identi...
2007-06-24 11:47:00 87
原创 数据库简介
1.网型2.层次型3.关系型4.面向对象的关系型5.面向对象型DBMS:数据库管理系统RDBMS:关系型数据库管理系统RODBMS:面向对象的关系型数据库管理系统现在比较流行的大型数据库有Oracle,SQLServer,Sybase,DB2,都采用了SQL(结构化查询语言)作为数据库操作语言.关系模型:1.关系数据结构(连接双方都是以表作为单位)2
2007-06-24 11:26:00 773
数据库简介
1.网型2.层次型3.关系型4.面向对象的关系型5.面向对象型DBMS:数据库管理系统RDBMS:关系型数据库管理系统RODBMS:面向对象的关系型数据库管理系统现在比较流行的大型数据库有Oracle,SQLServer,Sybase,DB2,都采用了SQL(结构化查询语言)作为数据库操作语言.关系模型:1.关系数据结构(连接双方都是以表作为单位)2...
2007-06-24 11:26:00 75
原创 Velocity用户指南
什么是Velocity?Velocity是基于Java的模板引擎。它允许Web页面开发者引用Java代码中定义的方法。Web设计者可以和Java程序开发者并行开发遵循MVC模式的Web站点。这意味着,Web设计者可以将精力放在好的Web站点设计上,而Java程序开发者可以将精力放在编写代码上。Velocity将Java代码从Web页面中分离,使Web站点更具长期可维护性,并提供了一种替代
2007-06-24 10:30:00 666
Velocity用户指南
什么是Velocity?Velocity是基于Java的模板引擎。它允许Web页面开发者引用Java代码中定义的方法。Web设计者可以和Java程序开发者并行开发遵循MVC模式的Web站点。这意味着,Web设计者可以将精力放在好的Web站点设计上,而Java程序开发者可以将精力放在编写代码上。Velocity将Java代码从Web页面中分离,使Web站点更具长期可维护性,并提供了一种替代...
2007-06-24 10:30:00 74
转载 Hibernate访问多个数据库
一、Hibernate访问数据库时加载的过程对于大多数使用Hibernate的朋友来说,通常使用一下方式来获得Configuration实例: Configuration configure = new Configuration().configure();在Hibernate中,Configuration是hibernate的入口。在实例化一个Configuration的时候,
2007-06-23 20:07:00 747
Hibernate访问多个数据库
一、Hibernate访问数据库时加载的过程对于大多数使用Hibernate的朋友来说,通常使用一下方式来获得Configuration实例: Configuration configure = new Configuration().configure();在Hibernate中,Configuration是hibernate的入口。在实例化一个Configuration的时候,...
2007-06-23 20:07:00 73
转载 处理超出打开游标的最大数异常
在执行如下代码时,经常会出现ora-01000: maximum open cursors exceeded异常for(int i=0;i { prepstmt = conn.prepareStatement(sql[i]); prepstmt.setBigDecimal(1,nb.getRealCost()); prepstmt.setString(2, a
2007-06-23 19:59:00 1389
处理超出打开游标的最大数异常
在执行如下代码时,经常会出现ora-01000: maximum open cursors exceeded异常for(int i=0;i < balancelist.size();i++){ prepstmt = conn.prepareStatement(sql[i]); prepstmt.setBigDecimal(1,nb.getRealCost());...
2007-06-23 19:59:00 104
原创 eclipse下使用xdoclet生成hibernate的hbm映射文件
当你在写Hibernate映射文件时,当属性有几十甚至上百个时,你是不是觉得体力不支啊?特别是大型项目,有几十上百个表时,不管是开发还是后期维护,你都要一个一个的对比,查找,添加,修改,好想有一个好工具能帮我们做这件事.有人用了MiddleGen,但是生成效果不好,需要我们手工修改.我下面介绍一下在eclipse环境(All In One Eclipse 3.1.1+MyEclipse 4
2007-06-23 18:57:00 2030
eclipse下使用xdoclet生成hibernate的hbm映射文件
当你在写Hibernate映射文件时,当属性有几十甚至上百个时,你是不是觉得体力不支啊?特别是大型项目,有几十上百个表时,不管是开发还是后期维护,你都要一个一个的对比,查找,添加,修改,好想有一个好工具能帮我们做这件事.有人用了MiddleGen,但是生成效果不好,需要我们手工修改.我下面介绍一下在eclipse环境(All In One Eclipse 3.1.1+MyEclipse 4...
2007-06-23 18:57:00 101
原创 实现CompositeUserType接口
Hibernate还提供了一个CompositeUserType借口,它不仅能完成和UserType相同的功能,而且还提供了对Hibernate查询语言(HQL)的支持.下面通过例子来介绍CompositeUserType接口的方法.假定在Customer类中包含了一个Name类型的name属性,代表客户的姓名.例1是Name类的源程序.例1:package mypack;impo
2007-06-23 18:23:00 1795
实现CompositeUserType接口
Hibernate还提供了一个CompositeUserType借口,它不仅能完成和UserType相同的功能,而且还提供了对Hibernate查询语言(HQL)的支持.下面通过例子来介绍CompositeUserType接口的方法.假定在Customer类中包含了一个Name类型的name属性,代表客户的姓名.例1是Name类的源程序.例1:package mypack;impo...
2007-06-23 18:23:00 95
原创 UserType取代枚举类型
枚举类型是一种常见的Java设计模式.在枚举类型的Java类中,定义了这个类本身是一些静态实例.例1定义了一个Gender类,它包含两个静态常量类型的Gender实例:Gender.FEMALE和Gender.MALE.Gender类有两个属性:sex和description.sex属性代表性别的缩写,可选值F和M;description属性代表性别的完整名字,可选值为"Female"
2007-06-23 17:30:00 1048
UserType取代枚举类型
枚举类型是一种常见的Java设计模式.在枚举类型的Java类中,定义了这个类本身是一些静态实例.例1定义了一个Gender类,它包含两个静态常量类型的Gender实例:Gender.FEMALE和Gender.MALE.Gender类有两个属性:sex和description.sex属性代表性别的缩写,可选值'F'和'M';description属性代表性别的完整名字,可选值为"Female"和...
2007-06-23 17:30:00 238
原创 Hibernate自定义类型取代Hibernate主件
本讲把Address设计为不可变类.所谓不可变类,是指当创建了这种类的实例后,就不允许修改它的属性.在Java API中,所有的基本类型的包装类,如Integer和Long类,都是不可变类,java.lang.String也是不可变类.在创建用户自己的不可变类时,可以考虑采用以下的设计模式.a.把属性定义为private final类型.b.不对外公开用于修改属性的setXXX()方法.
2007-06-22 22:51:00 753
Hibernate自定义类型取代Hibernate主件
本讲把Address设计为不可变类.所谓不可变类,是指当创建了这种类的实例后,就不允许修改它的属性.在Java API中,所有的基本类型的包装类,如Integer和Long类,都是不可变类,java.lang.String也是不可变类.在创建用户自己的不可变类时,可以考虑采用以下的设计模式.a.把属性定义为private final类型.b.不对外公开用于修改属性的setXXX()方法....
2007-06-22 22:51:00 60
原创 Hibernate自定义类型
Hibernate 提供了客户化映射类型接口,允许用户以编程的方式创建自定义的映射类型,以便把持久化类的任意类型的属性映射到数据库中.例1的PhoneUserType实现了net.sf.hibernate.UserType接口,它能够把Customer类的Integer类型的phone属性映射到CUSTOMER表的VARCHAR类型的PHONE字段.例1:package mypack;
2007-06-22 14:31:00 1076
Hibernate自定义类型
Hibernate提供了客户化映射类型接口,允许用户以编程的方式创建自定义的映射类型,以便把持久化类的任意类型的属性映射到数据库中.例1的PhoneUserType实现了net.sf.hibernate.UserType接口,它能够把Customer类的Integer类型的phone属性映射到CUSTOMER表的VARCHAR类型的PHONE字段.例1:package mypack;...
2007-06-22 14:31:00 284
Programming Windows
2007-08-18
Programming Windows with MFC 2th
2007-08-18
Programming Visual J++6.0
2007-08-18
Programming VisualC++
2007-08-18
Programming Windows Driver Model
2007-08-18
Programming Server-Side Applications for Windows2000
2007-08-18
Programming Windows CE
2007-08-18
Programming Microsoft Visual InterDev 6.0
2007-08-18
Programming Microsoft Outlook and Exchange
2007-08-18
Programing Microsoft Office2000 Web Components
2007-08-18
Programming Microsoft Access 2000
2007-08-18
Programming Distributed Applications with COM and Visual Basic 6.0
2007-08-18
Programming Applications for Microsoft Windows
2007-08-18
Programming Active Server Pages
2007-08-18
Network Programming for Microsoft Windows
2007-08-18
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人