关于between and和>= <=的区别

[复制链接]
查看11 | 回复0 | 2012-1-4 11:49:54 | 显示全部楼层 |阅读模式
本帖最后由 cyber_hu 于 2012-9-26 12:44 编辑
有个问题问诸位大侠:db2数据库,
create table am_bal(
fn_ent char(4) not null,
pro_cod char(2) not null,
bal decimal(18,2) not null
)
create index am_bal_idx on am_bal
(fn_ent asc,
pro_cod asc);
两条语句:
select bal from am_bal where fn_ent='1111' and pro_cod >='03' and pro_cod=用上了索引,='03'的记录,然后判断是否='03' 这两个条件。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行