I have large table from which I need to select some records based on options given by the user in a form. Filtering the table is no problem but the filtered records (around 300) need additional temporary fields. These fields will initially be set to the same value but the user needs the option of adjusting the fields for each record.
I started to program this by creating a temporary table, getting the user input and then copying across the records I need before finally updating the two additional fields with defaults:
DoCmd.RunSQL "INSERT INTO Rtmp SELECT DNI FROM Slst WHERE Est <10"
DoCmd.RunSQL "UPDATE Rtmp SET [score]= '" & Me.Score & "', [Res]=" & Me.Res
The final table is then presented in a form for the user to review and edit (only the two additional fields can be edited) before it is exported to a text file and the table is deleted. The text file is used by another program for further processing.
It works but I was wondering if there is a more elegant solution..
I started to program this by creating a temporary table, getting the user input and then copying across the records I need before finally updating the two additional fields with defaults:
DoCmd.RunSQL "INSERT INTO Rtmp SELECT DNI FROM Slst WHERE Est <10"
DoCmd.RunSQL "UPDATE Rtmp SET [score]= '" & Me.Score & "', [Res]=" & Me.Res
The final table is then presented in a form for the user to review and edit (only the two additional fields can be edited) before it is exported to a text file and the table is deleted. The text file is used by another program for further processing.
It works but I was wondering if there is a more elegant solution..
Comment