2 linked rookie Q's - filling fields and moving records

P

Purpleman

I do a weekly mailmerge to 200+ records.

1st question:
After mailing, I manually enter the mailing date into the field DateSent.
Can I enter the date into all the records at same time? Currently I do it by
copy and paste 1 by 1. (told you I was a rookie).

2nd question:
After doing the above, can I automate moving the records with a completed
DateSent field to another table in the same database?
 
A

Arvin Meyer MVP

Purpleman said:
I do a weekly mailmerge to 200+ records.

1st question:
After mailing, I manually enter the mailing date into the field DateSent.
Can I enter the date into all the records at same time? Currently I do it
by
copy and paste 1 by 1. (told you I was a rookie).

Assuming you have a field for knowing which records to mail (Mailed)

UPDATE tblMyData SET tblMyData.DateSent = Date()
WHERE (((tblMyData.DateSent) Is Null) AND ((tblMyData.Mailed)=True));

where tblMyData is the name of your table.
2nd question:
After doing the above, can I automate moving the records with a completed
DateSent field to another table in the same database?

Why would you want to? The Mailed field is more relational than using
separate tables to store the same data. But to answer your question, yes,
run an append query and a delete query.
 
P

Philip Herlihy

Purpleman said:
I do a weekly mailmerge to 200+ records.

1st question:
After mailing, I manually enter the mailing date into the field DateSent.
Can I enter the date into all the records at same time? Currently I do it by
copy and paste 1 by 1. (told you I was a rookie).

2nd question:
After doing the above, can I automate moving the records with a completed
DateSent field to another table in the same database?

For the first one, try an "update query". First, make a query which
selects all the records you'd like to update. Then click the Query Type
button in the toolbar to turn it into an Update query, and put the date
- or something that returns today's date: =now() - into the "update to"
item for that field.

I'd question whether it's a good idea to move the records from one table
to another. If you ever need to search, you'd be searching two tables
instead of one. Why not leave them in place, and use an additional
field (how about DateSent) to distinguish these records? In general,
you'd have one table for one "type of thing" - makes life easier down
the road. If you had to do this (e.g. daft boss) then you'd want an
"append" query together with a corresponding "delete" query.

HTH

Phil, London
 
P

purpleman

Understood. Thank you both for taking the time.

Philip Herlihy said:
For the first one, try an "update query". First, make a query which
selects all the records you'd like to update. Then click the Query Type
button in the toolbar to turn it into an Update query, and put the date
- or something that returns today's date: =now() - into the "update to"
item for that field.

I'd question whether it's a good idea to move the records from one table
to another. If you ever need to search, you'd be searching two tables
instead of one. Why not leave them in place, and use an additional
field (how about DateSent) to distinguish these records? In general,
you'd have one table for one "type of thing" - makes life easier down
the road. If you had to do this (e.g. daft boss) then you'd want an
"append" query together with a corresponding "delete" query.

HTH

Phil, London
 

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. After that, you can post your question and our members will help you out.

Ask a Question

Top