copying one row to another

Posted on 2014-08-18
Last Modified: 2014-08-18
I have a table named tblOrgRegistrations

I have a column named CDTESType and I want to transfer the data in this column to a column named SubGroup in the same table where the Agency column = CDTES

Is this correct below

UPDATE tblOrgRegistrations
SET SubGroup = CDTESType where Agency = 'CDTES'
Question by:al4629740
    LVL 23

    Assisted Solution

    Looks correct.  Back up your database and try it. :)
    LVL 11

    Assisted Solution

    by:Dany Balian
    yes, it's 100% correct as long as both data types are similar!
    LVL 142

    Accepted Solution

    it's correct if it's the same row.

    to copy from 1 row to another row, you will need to "update with join" with the same table, read up here:

    Featured Post

    Live: Real-Time Solutions, Start Here

    Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

    Join & Write a Comment

    When you hear the word proxy, you may become apprehensive. This article will help you to understand Proxy and when it is useful. Let's talk Proxy for SQL Server. (Not in terms of Internet access.) Typically, you'll run into this type of problem w…
    Slowly Changing Dimension Transformation component in data task flow is very useful for us to manage and control how data changes in SSIS.
    Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
    Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…

    734 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    24 Experts available now in Live!

    Get 1:1 Help Now