Manipulate duplicate rows
- From: bamboo <bamboo@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Fri, 15 Apr 2005 09:59:02 -0700
I have two of the exact same rows, but I want to change one field of one of
the rows. How do I do this?
i.e.
table_a
group name revenue
A jim 20
A jim 20
I want to change one jim to ken.
I tried
update table_a
set name = 'ken'
from (select top 1 * from table_a) as t1
where table_a.group = t1.group
but this updates both records
.
- Follow-Ups:
- Re: Manipulate duplicate rows
- From: Hugo Kornelis
- Re: Manipulate duplicate rows
- Prev by Date: Deploying vb.net english query application
- Next by Date: Re: Format Date in GroupBy query
- Previous by thread: Deploying vb.net english query application
- Next by thread: Re: Manipulate duplicate rows
- Index(es):
Relevant Pages
|
|