How to delete a field value?

  • Thread starter Thread starter lvensen
  • Start date Start date
L

lvensen

Hi,

In my table i stored the date values. I want to delete the date
value based on some condition. I used delete command to delete the field
value but it deletes the entire row. I also used update command, it showing
conversion error. I want to delete the date value or replace it with empty
space. How it is possible? Thanks in advance.
 
lvensen said:
Hi,

In my table i stored the date values. I want to delete the date
value based on some condition. I used delete command to delete the field
value but it deletes the entire row. I also used update command, it showing
conversion error. I want to delete the date value or replace it with empty
space. How it is possible? Thanks in advance.

UPDATE MyTable SET MyField=NULL WHERE MyCondition

or

UPDATE MyTable SET MyField='' WHERE MyCondition
 
Hi,

In my table i stored the date values. I want to delete the date
value based on some condition. I used delete command to delete the field
value but it deletes the entire row. I also used update command, it showing
conversion error. I want to delete the date value or replace it with empty
space. How it is possible? Thanks in advance.

A Date/Time field is NOT a string. It's stored as a number, a count of days
and fractions of a day since midnight, December 30, 1899. It can either be a
valid date between 1/1/100 and 12/31/9999, or it can be NULL; it cannot be a
string, even an empty string.

To blank out the date use an Update query and update the field to NULL.
 
Back
Top