Results 1 to 3 of 3
  1. #1
    Star Lounger
    Join Date
    Feb 2003
    Posts
    60
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Updating Records (2000)

    I have about 500 records I need to update. Each cell contains an 8 or 11 alpha/numeric character record, e.g. DEUTDEFF or PNCCUS33SEC. I need to update the values in the cells with 8 characters to add three XXX's to the end of each record, e.g. DEUTDEFFXXX, but I'm not sure how to set the parameters in the update query.

    Thanks for any help provided.

    Scott

  2. #2
    3 Star Lounger
    Join Date
    Dec 2000
    Location
    Manassas, Virginia, USA
    Posts
    363
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Updating Records (2000)

    Create a column in your query to test for the length of 8 in the field you are updating. The expression would be len([FieldName]). In the criteria for that column put 8. Next make the query an update query and indicate that you want to update to [FieldName]&"XXX"

    Be sure to replace [FieldName] in the example above with your fieldname.
    Judy Jones, Computer Training Specialist
    Manassas, Virginia

  3. #3
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Updating Records (2000)

    Judy has already given you excellent advice. An alternative would be to use the formula from the reply you got in the Excel forum:

    Create a query based on the table
    Add the field
    Change the query ot an Update query (in the Query menu)
    Don't set criteria
    Set the Update To: value to Left([FieldName] & "XXX", 11) where FieldName is the name of your field.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •