Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Comment: | {1808} added TSQLRestClientDB kind of test to mORMotBatchInsert.dpr sample #15 - trying to reproduce http://synopse.info/forum/viewtopic.php?id=2808 issue |
---|---|
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
8b0f3d5dfd1c6329d3d8f7b29655b24c |
User & Date: | ab 2015-08-19 10:38:46 |
2015-08-19
| ||
10:43 | {1809} fixed i18nAddLanguageItems() function check-in: 91e29f45aa user: ab tags: trunk | |
10:38 | {1808} added TSQLRestClientDB kind of test to mORMotBatchInsert.dpr sample #15 - trying to reproduce http://synopse.info/forum/viewtopic.php?id=2808 issue check-in: 8b0f3d5dfd user: ab tags: trunk | |
09:30 | {1807} initial TMemoEx Unicode compatibility - feedback is welcome! check-in: b654159d26 user: ab tags: trunk | |
Changes to SQLite3/Samples/15 - External DB performance/mORMotBatchInsert.dpr.
97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 |
finally batch.Free; end; finally db.Free; end; end; begin try Test; //if DebugHook<>0 then readln; except on E: Exception do ConsoleShowFatalException(E); end; end. |
> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > < > | |
97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 |
finally batch.Free; end; finally db.Free; end; end; const COUNT2 = 100000; procedure Test2; var db: TSQLRestClientDB; res: TIDDynArray; i: Integer; indy: TSQLIndy; timer: TPrecisionTimer; begin DeleteFile('test2.db3'); db := TSQLRestClientDB.Create(TSQLModel.Create([TSQLIndy]),nil,'test2.db3',TSQLRestServerDB); try db.Model.Owner := db; db.DB.LockingMode := lmExclusive; db.DB.Synchronous := smOff; db.Server.CreateMissingTables; timer.Start; db.BatchStart(TSQLIndy); indy := TSQLIndy.Create; try for i := 1 to COUNT2 do begin indy.indikey := IntToString(i); indy.hasdata := i and 1=0; indy.sex := 'Male'; indy.famc := i; indy.fams := i*10; indy.todo := i+100; indy.firstancestralloop := i*2; db.BatchAdd(indy,true); end; finally indy.Free; end; writeln('Prepared ',COUNT2,' rows in ',timer.Stop); timer.Start; db.BatchSend(res); write('Inserted ',COUNT2,' rows in ',timer.Stop); writeln(' i.e. ',timer.PerSec(COUNT2),' per second'); finally db.Free; end; end; begin try Test; // Test2 readln; except on E: Exception do ConsoleShowFatalException(E); end; end. |
Changes to SynopseCommit.inc.
1 |
'1.18.1807'
|
| |
1 |
'1.18.1808'
|