当前位置:主页>delphi源码/MIS软件> 文章内容

如何使用一个SQL 语句修改一个由多个表查询出的数据集合

发布时间:2010-01-21 | QQ免费站
1楼: 如何使用一个SQL 语句修改一个由多个表查询出的数据集合 字串4

2楼: 跟單表差不多阿 update tableA set tableA.field1=‘a‘ from tableA,tableB where tableA.field2=tableB.field3 .... update tableA set tableA.field1=tableB.field4 from tableA,tableB where tableA.field2=tableB.field3 不要聯合查詢錯了就可以

字串7

3楼: 怎么总是在 FROM 那里包错啊,语句是很简单的啊

字串9

4楼: 我使用的联合查询可以查询出结果,按victor_zh的要求,该了前面的内容就是报 FROM 不是合法的KEY 字串1

5楼: 我使用的数据库是PARADX和SQL SERVER
字串8

6楼: 我的语句是 update c_used_channel set b.upper_limit=3000 from c_used_channel b,c_used_model a where b.area_id=1 and b.bureau_id=1 and b.model_id=1 and host_id=21 and a.model_label=‘YZ_CPEM8500_TOP1‘ and b.channel_id=1 and b.channel_type=0 AND b.area_id=a.area_id and b.bureau_id=a.bureau_id and b.model_id=a.model_id and a.board_num=b.board_id
字串8

7楼: 改成 update b set b.upper_limit=3000 .... 或者 update c_used_channel set c_used_channel.upper_limit=3000 ..... 或者 update c_used_channel set upper_limit=3000....
字串5