Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 314
  • Last Modified:

How to update database automatically

I want to refresh a database (delete some record) every 10 minutes. Can I implement it with trigger? If so, how to do it?

Thanks
0
JamesCao
Asked:
JamesCao
2 Solutions
 
JamesCaoAuthor Commented:
Sorry, I just want to refresh a table instead of a database.
0
 
nussiCommented:
If you're using a DBRS which allows you to schedule tasks, you should be able to do that
With SQL Server for example you can execute Transact-SQL in a task that would be executed every ten minutes
0
 
BuffyTVS65Commented:
Triggers implement something based on a triggering event e.g. an insert/delete.  You probably want to write something as a function / procedure and implement it using the DBMS_JOB package which enables you to schedule it to run every 10 minutes.
0
 
BuffyTVS65Commented:
Of course my previous answer depends on the RDBMS - I was writing it as an oracle guy, so sorry if not applicable.
0
 
Tom KnowltonWeb developerCommented:
JamesCao,
No comment has been added lately (217 days), so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area for this question:

RECOMMENDATION: split points between nussi http:#7987121 and BuffyTVS65 http:#7987167

Please leave any comments here within 7 days.

-- Please DO NOT accept this comment as an answer ! --

Thanks,

knowlton
EE Cleanup Volunteer
0

Featured Post

Nothing ever in the clear!

This technical paper will help you implement VMware’s VM encryption as well as implement Veeam encryption which together will achieve the nothing ever in the clear goal. If a bad guy steals VMs, backups or traffic they get nothing.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now