- 浏览: 101500 次
- 性别:
- 来自: 广州
最新评论
-
zhangyulove911:
读XML in a Nutshell (10) -
sunzihao128858:
非常好
Red5源代码分析 - 关键类及其初始化过程 -
还是小鬼:
受用了
Red5源代码分析 - 关键类及其初始化过程 -
qiyue49:
如果有flex4版本,可以直接把C:\Program Fil ...
[转]Flex的中文编译 -
faylai:
标题党骗流量!
20090209-20090211 (about Red5 and Flex)
文章列表
1.transaction [done]2.cache3.session operations4.class mapping5.hql6.filter, interceptor, statistic, session context
- 2009-01-20 15:43
- 浏览 447
- 评论(0)
1.Three code styles
Use hibernate's transaction:
session.beginTransaction();
// ... interact with database
session.getTransaction().commit();
Use JTA:
javax.transaction.UserTransaction tx = new InitialContext().lookup("javax.transaction.UserTransaction");
// ... use session to interact ...
- 2009-01-20 10:11
- 浏览 931
- 评论(0)
下载mysql 5.1 和 gui tool,安装,之后用gui tool连接,一切非常顺利。
下载mysql-connector-java-5.1,按照里面的pdf文档所写的配置,顺利连上db:
Class.forName("com.mysql.jdbc.Driver").newInstance();
// 据文档上描述,newInstance()是为了work arround some errors
DriverManager.getConnection("jdbc:mysql://localhost/test", "root" ...
- 2009-01-10 12:21
- 浏览 656
- 评论(0)
方法是放一个text field覆盖在drop down list上,使用javascript,当text field的值改变时改变drop down list的选项,反之drop down list选择改变时更新text field的值。
- 2009-01-09 15:36
- 浏览 1020
- 评论(0)
1. When automatic versioning is used, hibernate generates the following sql:
update products set version=?, name=?, description=?, unitCost=?, pubTime=? where id=? and version=?
Note that using such sql, you don't need to select the version from database to compare with current version. 2. Other way ...
- 2009-01-08 17:29
- 浏览 762
- 评论(0)
启动hsqldb:
cd ..\data //数据库文件会放到这个目录,如果不存在hsqldb会自动创建java -cp ../lib/hsqldb.jar org.hsqldb.Server -database.0 file:mydb -dbname.0 xdb //-database.0 file:mydb 数据库文件的名字,-dbname.0 xdb 数据库的名称
连接到hsqldb:
Class.forName("org.hsqldb.jdbcDriver");
- 2009-01-08 17:22
- 浏览 887
- 评论(0)
Summary for JTA
- 博客分类:
- Java
JTA is useful not only for different database, but also for different connection to the same database.
Transaction manager manage Transaction by begin / suspend / getTransaction / setTransactionTimeout, its other methods just delegate to Transaction
Transaction then delegate call to each XAResour ...
- 2009-01-06 17:06
- 浏览 652
- 评论(0)
1 Overview XML Schema mainly defines reference and datatype, reference can be <element> or <attribute>, and both will refer to a certain datatype. Datatype may in turn contains references (<attribute for <complexType> and <element> for <complexContent>). 1.1 Differ ...
- 2009-01-05 16:31
- 浏览 1308
- 评论(0)
2009年1月4日,房贷商业贷款利率8.5折酝酿变7折,加上去年9月份以来连续5次降息,对于优质房贷客户而言,今年起5年以上住房商业贷款最优惠利率可由去年的6.6555%下调为4.158%。5年以上个人住房公积金贷款利率仍为3.87%。 2009-01-06 ...
- 2009-01-04 22:51
- 浏览 573
- 评论(0)
1.<unique> acts much like <key> except that <unique> allow value to be null, both require values to be unique with specific scope (under the element which <unique> or <key> is defined). <keyref> can refer to <unique> or <key>, it dose not aware to any s ...
- 2009-01-02 09:51
- 浏览 654
- 评论(0)
1.About <choice>, <sequence>, <all> and <group>, also about "max/min occurs". What and why <all> special? There are also <element> and <any>.
2.About namespace. The "namesapce" attribute in <any> and <anyAttribute>.
3.For &l ...
- 2009-01-02 09:27
- 浏览 673
- 评论(0)
1.The xml schema type system:
(contains attribute?)
- SimpleType
- ComplexType (contains element?)
- SimpleContent
- ComplexContent (can be mixed with character?)
- Element Only
- Mixed
For those "Y", unless otherwise explained, they should be derived from the same ...
- 2008-12-30 16:05
- 浏览 780
- 评论(0)
There are two ways to change the default
locale. The first is to set it on the command line:
> java
-Duser.language=2-char-language-code -Duser.region=2-char-country-code
MyApp
// Set only language code
> java -Duser.language=en
-Duser.region= MyApp
// Set language and country code
> java
...
- 2008-12-28 16:36
- 浏览 753
- 评论(0)
1.The anySimpleType are quite special as all primitive type is considered as derived by restriction from anySimpleType, but they are call "primitive" (normally, primitive types don't derive from other). The anySimpleType is the base type for anySimpleType, also for those complex types, note ...
- 2008-12-26 16:18
- 浏览 717
- 评论(0)
1.A datatype is composed of a value space, a lexical space and facets. there's a one2many relationship between value space and lexical space. It's said that facet define aspect of a value space, but can't it be lexical space? Also, what's Fundamental facets and Constraining or Non-fundamental facets? ...
- 2008-12-25 17:50
- 浏览 562
- 评论(0)