troubleshooting Question

Run an action on recently added records to a table

Avatar of anthonytr
anthonytrFlag for United Kingdom of Great Britain and Northern Ireland asked on
Microsoft AccessVBAMicrosoft SQL Server
13 Comments1 Solution121 ViewsLast Modified:
Hi,

I have an INSERT SQL query which is contained within a LOOP action.  When the LOOP is completed I need to ask the user if they want to run a task relating to the new records which were just inserted.

My plan at the moment is to have a new field added to the table which the data is being inserted and name it NEW (yes/no).  When new records are inserted, the insert query will assign them YES.  At the end of the process when the user is asked if they want to see/print the newly inserted records I can then run a select query based on that table where the NEW field = true/1.  Once this has run I will set all TRUE fields to FALSE.

Does this method make sense?  Am I going about this totally wrong?  Is there a better and cleaner way of approaching this?  Really happy to see suggestions of simpler coding.

Thanks
Anthony
ASKER CERTIFIED SOLUTION
Join our community to see this answer!
Unlock 1 Answer and 13 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 13 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros