Topic: To deduce in the form request runtime to a DB
Kind hour, !
I perform laboratory operation, its essence in that in to generate a certain amount of the casual data in the table and to count time of their performance.
Option Compare Database Sub randomDigits (tableName, fldOt, fldDo, n) Start_time = Time () Dim i Randomize With CurrentDb. OpenRecordset ("select * from [" AND tableName AND "]") For i = 1 To n .AddNew ! number = Rnd (i) * (fldDo - fldOt) + fldOt .update Next End With End_time = Time () End Sub Sub button_Click ()//procedure for data reading from appropriate fields of the form n = Number19 () fldOt = number_ot () fldDo = number_do () randomDigits "table", number_ot, number_do, n End Sub
How it is possible to count not runtime of this code, namely time from beginning to end creations necessary kol-va records in a database and to deduce in the form?