Thanks Steve. Thats exactly what I was after, and I didn't realise it
was that simple! (No wonder my efforts with Google were of no use!)

Regards

Darren Tracey

On Oct 4, 11:59 am, "Steve Onnis" <[EMAIL PROTECTED]> wrote:
> UPDATE  TableA
> SET             ColumnC = ColumnB
>
> Simple?
>
>
>
> -----Original Message-----
> From: cfaussie@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf
>
> Of Darren Tracey
> Sent: Thursday, 4 October 2007 11:57 AM
> To: cfaussie
> Subject: [cfaussie] SQL problem
>
> Sorry about posting this here, but I'm having a fuzzy brain day and can't
> work out how to do this.
>
> I have a table in an MSSQL DB which we shall call TableA.
> It has a bunch of fields including ColumnA, ColumnB, and ColumnC.
> ColumnA is the unique identifier.
> I need a single SQL statement that will copy the values from ColumnB for
> each record and put them into ColumnC for the same record in the same table.
>
> I'm not after a CF solution for this (eg. select all records from table,
> loop over query results, update each record).
> I've got a nagging feeling that I can do this in a single SQL statement
> (some sort of update with a nested select), and that I've done it before,
> but I can't remember how to do it and Google is not being my friend today.
>
> Any suggestions?
>
> Regards
>
> Darren Tracey- Hide quoted text -
>
> - Show quoted text -


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"cfaussie" group.
To post to this group, send email to cfaussie@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cfaussie?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to