Hello all: I was reading through a couple of sqlite tutorials and I noticed examples of timestamping database entries by using triggers. I wanted to ask people's opinion about using triggers to timestamp records in a database.
Which is 'better': using a trigger to timestamp records or explicity adding the timestamp in the sql statement? In my own analysis (brief < 5 min), I have thought of the following pro's and con's. 1) Faster to do the timestamp in the sql statement, since it does not require activation of the trigger. 2) Query looks 'cleaner', not having an explicit datetime() inside 3) Can switch the timestamp between UTC and localtime by modifying the trigger as opposed to changing and recompiling the application. Of course this was just a quick thought on my way home from work. I am sure I am forgetting several important things. I would love to hear any other reasons for or against using triggers for automatic timestamping. -- Thanks, Rich Rattanni ----------------------------------------------------------------------------- To unsubscribe, send email to [EMAIL PROTECTED] -----------------------------------------------------------------------------