Updating a record across two tables

  • Thread starter Thread starter CQMMAN
  • Start date Start date
C

CQMMAN

OK, I am finally getting somewhere.

I now have two tables.

tbInvoices
ID
transdate
InvoiceNum
PartNum
Quantity
SiteID
Notes

tblProducts
partnum
Partdesc

There is a standard join between Partnum on both tables.

I would like a query that I can base a form on, that would allow me to enter
the details, but only enter the partnum once. Once the part number is
entered on the form for tblinvoices, it should automatically create a record
for it in tblproducts maybe?

Any help would be appreciated.

Cheers
CQMMAN
 
CQMMAN said:
OK, I am finally getting somewhere.

I now have two tables.

tbInvoices
ID
transdate
InvoiceNum
PartNum
Quantity
SiteID
Notes

tblProducts
partnum
Partdesc

There is a standard join between Partnum on both tables.

I would like a query that I can base a form on, that would allow me to enter
the details, but only enter the partnum once. Once the part number is
entered on the form for tblinvoices, it should automatically create a record
for it in tblproducts maybe?

Any help would be appreciated.

Cheers
CQMMAN

BTW, this is the current SQL statement I have for the query, but I don't
think it is the best way..

SELECT tblInvoices.*, tblProducts.PartNum, tblProducts.PartDescription
FROM tblProducts INNER JOIN tblInvoices ON tblProducts.PartNum =
tblInvoices.PartNum;

Cheers
 
Back
Top