首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 数据库 > 其他数据库 >

SQLite的多个字段update语句

2012-02-17 
求一个SQLite的多个字段update语句假设a 表af1,af2,atypeb 表bf1,bf2,btype

求一个SQLite的多个字段update语句
假设
a 表
af1,af2,atype
b 表
bf1,bf2,btype
======================================
下面的语句可以执行
update a set af1=(select bf1 from b where btype=a.atype);

但是我想同时将af2也更新了怎么写?

[解决办法]
update a set af1=(select bf1 from b where btype=a.atype),
af2=(select bf2 from b where btype=a.atype)

热点排行