Delete Query Please help

  • Thread starter Thread starter TotallyConfused
  • Start date Start date
T

TotallyConfused

How do I delete the contents of column? I have a table where I need to empty
the contents of a column(field) there are thousands of records. There are
some records that have data in this field I need to make this field blank for
all the records in the table. How do I this please? Thank you for any help.
 
How do I delete the contents of column? I have a table where I need to empty
the contents of a column(field) there are thousands of records. There are
some records that have data in this field I need to make this field blank for
all the records in the table. How do I this please? Thank you for any help.

A Delete operation in Access *deletes entire records*, all or nothing.

What you want to do (it seems) is to *update* the content of records, without
deleteing them - updating an individual field to NULL (blank, empty,
undefined).

To do so use an Update query like

UPDATE mytable
SET victimfield = Null
WHERE victimfield IS NOT NULL;

Copy and paste this into the SQL view of a new query, adding your own table
and fieldnames of course. It will blank out the field victimfield in all
records where it isn't null already.
 
Back
Top