Compact SQL update record

Discussion in 'microsoft.public.sqlserver.ce' started by RonR399, Jan 2, 2010.

  1. RonR399

    RonR399 Guest

    I want to use databindings for viewing & printing. I use SQL for queries. For
    now I already have this fairly well mastered.

    what I need is code to select a particular record and update the desired
    column in the desired row. I can use the Primary Key from the databindings to
    target the selected column & row.

    I would NEVER want(or need) to update a whole row.
    I would NEVER want(or need) to update more than one record at a time.

    I just need code to open the database, then enter a command to update the
    column of the selected row(that was selected with the databindings).

    I hope I have been clear.
     
    RonR399, Jan 2, 2010
    #1
    1. Advertisements

  2. It seems like any SQL reference will tell you what to do with an UPDATE
    query.

    UPDATE MyTable SET OneColumn='new value' WHERE PrimaryKeyColumn='primary key
    value';

    Paul T.
     
    Paul G. Tobey [eMVP], Jan 4, 2010
    #2
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.