How to change value of field in one to many relation ship

S

Shetty

Dear Freinds

I have 2 tables with 1 to many relation ship
table1 customer
table2 collection sub
both of them are linked through customer ID

I want to update one of the field 'lastAMCdate' which is equal to
'AMCtodate' in the latest enrty ie last row.

Please advise how I can update programatically above field in custoemr table

Please advise


Rgds

Ramesh shetty
 
B

Bob Quintal

Dear Freinds

I have 2 tables with 1 to many relation ship
table1 customer
table2 collection sub
both of them are linked through customer ID

I want to update one of the field 'lastAMCdate' which is equal to
'AMCtodate' in the latest enrty ie last row.

Please advise how I can update programatically above field in
custoemr table

Please advise


Rgds

Ramesh shetty

You should not be updating a value in the customer table, because
this violates normalization principles. All you need to do is use
the DMax("AMCtodate","[collection sub]","[Customer ID] = " &
[Customer].[Customer ID]) as an expression in any query, form or
report where you want the lastAMCdate.
 

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