没有合适的资源?快使用搜索试试~ 我知道了~
资源推荐
资源详情
资源评论
永久链接: http://pphqq.iteye.com/blog/1172351
2011-09-15
最近用到blob类型的字段,在网上看了看,大部分都没成功。自己试验些时间,整理个可以运行的,以便将来用的时候不用在到网上搜来搜去的了!
闲话少说,只将关键代码贴出来
1.表
Java代码
create table TBL_SYS_BULLIT (
TPI_ID VARCHAR2(10) not null,
TPI_TITLE VARCHAR2(200) not null,
TPI_CONTENT_URL BLOB )
2.实体BulletinVo.java
Java代码
public class BulletinVo {
private String tpiId;
private String tpiTitle;
private byte[] tpiContentUrl;
public BulletinVo() {
}
public String getTpiId() {
2011-09-15
最近用到blob类型的字段,在网上看了看,大部分都没成功。自己试验些时间,整理个可以运行的,以便将来用的时候不用在到网上搜来搜去的了!
闲话少说,只将关键代码贴出来
1.表
Java代码
create table TBL_SYS_BULLIT (
TPI_ID VARCHAR2(10) not null,
TPI_TITLE VARCHAR2(200) not null,
TPI_CONTENT_URL BLOB )
2.实体BulletinVo.java
Java代码
public class BulletinVo {
private String tpiId;
private String tpiTitle;
private byte[] tpiContentUrl;
public BulletinVo() {
}
public String getTpiId() {
return tpiId;
}
public void setTpiId(String tpiId) {
this.tpiId = tpiId;
}
public String getTpiTitle() {
return tpiTitle;
}
public void setTpiTitle(String tpiTitle) {
this.tpiTitle = tpiTitle;
}
public byte[] getTpiContentUrl() {
return tpiContentUrl;
}
public void setTpiContentUrl(byte[] tpiContentUrl) {
this.tpiContentUrl = tpiContentUrl;
}
}
3.sqlMapConfig.xml
Java代码
}
public void setTpiId(String tpiId) {
this.tpiId = tpiId;
}
public String getTpiTitle() {
return tpiTitle;
}
public void setTpiTitle(String tpiTitle) {
this.tpiTitle = tpiTitle;
}
public byte[] getTpiContentUrl() {
return tpiContentUrl;
}
public void setTpiContentUrl(byte[] tpiContentUrl) {
this.tpiContentUrl = tpiContentUrl;
}
}
3.sqlMapConfig.xml
Java代码
剩余5页未读,继续阅读
资源评论
pphqq
- 粉丝: 1
- 资源: 8
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功