
February 10th, 2004, 06:31 AM
|
|
Registered User
|
|
Join Date: Feb 2004
Posts: 1
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
|
Ado recordset + additional info
Hello,
I have connected two datagrids in one form using adodc1 and adodc2 where Adodc2.recordsource = " select from meat(My 1st table) where Adodc1.recordset!meatId(primary key) = " & Adodc2.recordset!MeatId (on the other table Deliveries)
So my second table called deliveries is displayed where its primary key(meatId) is equal to that of the first table. A 1:N connection. I hope this makes sense so far.
What I want to do is to be able to add data to my second table and at the same time update data on my first table.
i.e. My second table called deliveries has a field called quantity(deliveries.quantity) and my first table(meat) has a field called NumberInStock(meat.NumberInstock).
So basically everytime I add data to my second table, I want whatever I have input as my quantity value to be added to my meat.NumberInStock value.
I hope this is clear.
Example code is most welcome. Thank you in advance.
Mark
ps to make this query clear I have included a screen shot of the form in question. This might help
Last edited by mmisumi : February 11th, 2004 at 06:55 AM.
|