
single field to multiple field update qry
Does anyone know how to create an update qry for multiple fields in tbl1
from a single field in tbl2?
eg. [Tbl_Invoice] has field [InvoiceNumber]... there are multiple records
per customer which need to be placed into [Tbl_Invoice_History] in fields
[History2], [History3], [History4].
I have tried to update the fields with the previous history field, but keep
getting parameters when running it.
sql below:
UPDATE Tbl_Tap_Current RIGHT JOIN TBL_Invoice_Main ON Tbl_Tap_Current.CID =
TBL_Invoice_Main.CID SET Tbl_Tap_Current.SalesHistoryInv1 =
[tbl_invoice_main].[invoicenumber], Tbl_Tap_Current.SalesHistoryInv2 =
[tbl_invoice_main].[SalesHistoryInv1], Tbl_Tap_Current.SalesHistoryInv3 =
[tbl_invoice_main].[SalesHistoryInv2], Tbl_Tap_Current.SalesHistoryInv4 =
[tbl_invoice_main].[SalesHistoryInv3], Tbl_Tap_Current.SalesHistoryInv5 =
[tbl_invoice_main].[SalesHistoryInv4], Tbl_Tap_Current.SalesHistoryInv6 =
[tbl_invoice_main].[SalesHistoryInv5];