Don't think iif() will work in an UPDATE since it won't change any
underlying data. It does affect what gets displayed in SELECT query results
but an Update query doesn't return any records to display.
UPDATE MyTable
SET [CC Number] = 0
WHERE ([Processing Date]+8>Now;
HTH,
>I have a table that has sensitive data on it and Management wants me to
> delete that piece of data after seven days have elapsed. I have made a
[quoted text clipped - 16 lines]
> Thanks!
> Kent
Show us the SQL. Open the query in design view. Next go to View, SQL View
and copy and past it here.
I'll take a WAG at it without the above data. In the criteria for the
Processing Date field put < Now() - 8
Run it as a select query and see if it returns the correct records. If so,
change it to an update query and put 0 in the Update To under the cc number
field..
Of course test the above in a copy of the table or entire database first.

Signature
Jerry Whittle, Microsoft Access MVP
Light. Strong. Cheap. Pick two. Keith Bontrager - Bicycle Builder.
> I have a table that has sensitive data on it and Management wants me to
> delete that piece of data after seven days have elapsed. I have made a
[quoted text clipped - 13 lines]
> Thanks!
> Kent
Bunky - 28 Feb 2007 14:55 GMT
Here is the SQL that was requested:
SELECT Cancellation_New.[CC Number], Cancellation_New.[CC Expire Date],
Cancellation_New.[Processing Date], IIf([Processing
Date]+8>Now(),'0000000000000000',[cc number]) AS exp1r, IIf([Processing
Date]+8>Now(),'0000',[CC Expire Date]) AS expr2
FROM Cancellation_New;
I was experimenting some so let me know what you think.
Thanks,
Kent
> Show us the SQL. Open the query in design view. Next go to View, SQL View
> and copy and past it here.
[quoted text clipped - 25 lines]
> > Thanks!
> > Kent