<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns:p="urn:schemas-microsoft-com:office:powerpoint" xmlns:a="urn:schemas-microsoft-com:office:access" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:s="uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:rs="urn:schemas-microsoft-com:rowset" xmlns:z="#RowsetSchema" xmlns:b="urn:schemas-microsoft-com:office:publisher" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:c="urn:schemas-microsoft-com:office:component:spreadsheet" xmlns:odc="urn:schemas-microsoft-com:office:odc" xmlns:oa="urn:schemas-microsoft-com:office:activation" xmlns:html="http://www.w3.org/TR/REC-html40" xmlns:q="http://schemas.xmlsoap.org/soap/envelope/" xmlns:rtc="http://microsoft.com/officenet/conferencing" xmlns:D="DAV:" xmlns:Repl="http://schemas.microsoft.com/repl/" xmlns:mt="http://schemas.microsoft.com/sharepoint/soap/meetings/" xmlns:x2="http://schemas.microsoft.com/office/excel/2003/xml" xmlns:ppda="http://www.passport.com/NameSpace.xsd" xmlns:ois="http://schemas.microsoft.com/sharepoint/soap/ois/" xmlns:dir="http://schemas.microsoft.com/sharepoint/soap/directory/" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:dsp="http://schemas.microsoft.com/sharepoint/dsp" xmlns:udc="http://schemas.microsoft.com/data/udc" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:sub="http://schemas.microsoft.com/sharepoint/soap/2002/1/alerts/" xmlns:ec="http://www.w3.org/2001/04/xmlenc#" xmlns:sp="http://schemas.microsoft.com/sharepoint/" xmlns:sps="http://schemas.microsoft.com/sharepoint/soap/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:udcs="http://schemas.microsoft.com/data/udc/soap" xmlns:udcxf="http://schemas.microsoft.com/data/udc/xmlfile" xmlns:udcp2p="http://schemas.microsoft.com/data/udc/parttopart" xmlns:wf="http://schemas.microsoft.com/sharepoint/soap/workflow/" xmlns:dsss="http://schemas.microsoft.com/office/2006/digsig-setup" xmlns:dssi="http://schemas.microsoft.com/office/2006/digsig" xmlns:mdssi="http://schemas.openxmlformats.org/package/2006/digital-signature" xmlns:mver="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns:mrels="http://schemas.openxmlformats.org/package/2006/relationships" xmlns:spwp="http://microsoft.com/sharepoint/webpartpages" xmlns:ex12t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:ex12m="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:pptsl="http://schemas.microsoft.com/sharepoint/soap/SlideLibrary/" xmlns:spsl="http://microsoft.com/webservices/SharePointPortalServer/PublishedLinksService" xmlns:Z="urn:schemas-microsoft-com:" xmlns:st="" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv=Content-Type content="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 12 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]-->
<style>
<!--
/* Font Definitions */
@font-face
        {font-family:Wingdings;
        panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";
        color:black;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";
        color:black;}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";
        color:black;}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
        {mso-style-priority:99;
        mso-style-link:"Balloon Text Char";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:8.0pt;
        font-family:"Tahoma","sans-serif";
        color:black;}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:Consolas;
        color:black;}
span.BalloonTextChar
        {mso-style-name:"Balloon Text Char";
        mso-style-priority:99;
        mso-style-link:"Balloon Text";
        font-family:"Tahoma","sans-serif";
        color:black;}
span.EmailStyle22
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle23
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
-->
</style>
<!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body bgcolor=white lang=EN-NZ link=blue vlink=purple id=MailContainerBody
name="Compose message area">
<div class=WordSection1>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>I myself still suspect a logic fault in the code running on the Windows
2000 machine.<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>Sidebar: You refer to this Windows 2000 machine as a “slow
machine”. But Trust Me (tm). It is *<b>not</b>* a slow
machine compared to the first PC kit I worked on when developing Windows clent/server
applications handling scores, if not hundreds of transactions per second
(certainly more than 5!), back in 1991 when we were running Windows/386 (and
later Windows 3.0) on the clients and Novel NetWare on the servers with a Gupta
SQLBase NLM, and the client code was running in an interpreted 4GL! (Gupta SQL/Windows).<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>The server was of course a much faster machine than the
client. I think the server was a powerful 486 CPU blazing along at 33MHz and
stuffed to the gills with as much as 32 MB of RAM, whilst the clients were
typically 12 MHz 286’s with 33 MHz 386’s reserved for our development
machines and “super users”, with as much as 8 or even 16 MB of RAM.<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>And no, not a single one of those “M”s should be a “G”.<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'> <o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>Dammit but I feel old sometimes...<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:Wingdings;
color:#1F497D'>J</span><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>As to your supplementary question... what do you mean by “Transaction
ID” ?<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>If you mean the ID’s generated *<b>within</b>* the
transaction, then the ID’s will be available as soon as they have been
generated to the process running within that transaction, even before the
transaction has been committed.<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>The ID’s (and the records) would not normally be available
to other processes until the transaction has committed, depending on the
isolation level in which those other transactions are themselves running.
For transactions isolated from that which generates the ID and the record, the
processing will be sufficiently fast that – as far as I can surmise
from the scenario you describe - the commit of the transaction and the
availability of the data created within that transaction will to all intents
and purposes be instantaneous.<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<div>
<div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm'>
<p class=MsoNormal><b><span lang=EN-US style='font-size:10.0pt;font-family:
"Tahoma","sans-serif";color:windowtext'>From:</span></b><span lang=EN-US
style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>
delphi-bounces@delphi.org.nz [mailto:delphi-bounces@delphi.org.nz] <b>On Behalf
Of </b>John Bird<br>
<b>Sent:</b> Thursday, 22 July 2010 14:51<br>
<b>To:</b> NZ Borland Developers Group - Delphi List<br>
<b>Subject:</b> Re: [DUG] Firebird transactions<o:p></o:p></span></p>
</div>
</div>
<p class=MsoNormal><o:p> </o:p></p>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:windowtext'>Each transaction fires a inserts one line in one table and
populates about 20 fields, and inserts multiple lines in another with similar
number of fields. And multiple of these transactions are
coming from the slow Windows 2000 box each second in this burst.</span><span
style='color:windowtext'><o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='color:windowtext'> <o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:windowtext'>Within each transaction the program fires the generator once
for ID for one table, and once for each line ID of the other table, and writes
one line to a log file after the transaction commits. The
generator is being fired separately for the occasional duplicate transactions
(ie they have different ID's even though other fields are the same) yet
only one line appears in the log file. Hence the mystery!</span><span
style='color:windowtext'><o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='color:windowtext'> <o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:windowtext'>So in answer to what you asked, it is several transactions
per second, each involving inserts into two tables.</span><span
style='color:windowtext'><o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='color:windowtext'> <o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:windowtext'>From what everyone is implying it looks like Firebird should
not be the culprit with this volume on a fast server unless an extremely
slow workstation can slow any of the transactional stuff down.....
This is good, mainly wanted to eliminate the Firebird server as a area to
investigate.</span><span style='color:windowtext'><o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='color:windowtext'> <o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:windowtext'>Practical question - if I want to do a query on the
transaction ID after it is finished is it visible the exact instant after
the commit transaction is done, or may there any lag while Firebird does
its housekeeping - or while some cached stuff on the slow workstation is
not saved yet?</span><span style='color:windowtext'><o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='color:windowtext'> <o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='color:windowtext'> <o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:windowtext'>John</span><span style='color:windowtext'><o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='color:windowtext'><br>
<o:p></o:p></span></p>
</div>
<div>
<div>
<div>
<p class=MsoNormal style='background:whitesmoke'><b><span style='font-size:
10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>From:</span></b><span
style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'> <a
href="mailto:Cameron.Hart@flowsoftware.co.nz"
title="Cameron.Hart@flowsoftware.co.nz">Cameron Hart</a> <o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal style='background:whitesmoke'><b><span style='font-size:
10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>Sent:</span></b><span
style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>
Thursday, July 22, 2010 1:56 PM<o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal style='background:whitesmoke'><b><span style='font-size:
10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>To:</span></b><span
style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'> <a
href="mailto:delphi@delphi.org.nz" title="delphi@delphi.org.nz">NZ Borland
Developers Group - Delphi List</a> <o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal style='background:whitesmoke'><b><span style='font-size:
10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>Subject:</span></b><span
style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>
Re: [DUG] Firebird transactions<o:p></o:p></span></p>
</div>
</div>
</div>
<div>
<p class=MsoNormal><span style='color:windowtext'><o:p> </o:p></span></p>
</div>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>Is transaction the right term? Or do you really mean records
– ie you are inserting 5 records per second for 20-30 seconds.<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>Running a series of insert statements (within one transaction)
against firebird I can get up to 2500 per second on a laptop alone.<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<div>
<div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm'>
<p class=MsoNormal><b><span lang=EN-US style='font-size:10.0pt;font-family:
"Tahoma","sans-serif";color:windowtext'><o:p> </o:p></span></b></p>
<p class=MsoNormal><b><span lang=EN-US style='font-size:10.0pt;font-family:
"Tahoma","sans-serif";color:windowtext'>From:</span></b><span lang=EN-US
style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'> <a
href="mailto:delphi-bounces@delphi.org.nz">delphi-bounces@delphi.org.nz</a> [mailto:delphi-bounces@delphi.org.nz]
<b>On Behalf Of </b>John Bird<br>
<b>Sent:</b> Thursday, 22 July 2010 1:27 p.m.<br>
<b>To:</b> NZ Borland Developers Group - Delphi List<br>
<b>Subject:</b> Re: [DUG] Firebird transactions<o:p></o:p></span></p>
</div>
</div>
<p class=MsoNormal><o:p> </o:p></p>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif"'>The
error is same transaction going in twice, each one with different ID (from the
Generator) but otherwise the same. The generator is fired by the
program, so looks like its the calling program somehow doing the same
processing twice. Not helped by the fact that the program is running
these bursts of transactions on an old slow Windows 2000 box...just wanted to
eliminate Firebird not keeping up.</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal> <o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif"'>John</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal> <o:p></o:p></p>
</div>
<div>
<p class=MsoNormal>Hi<br>
<br>
FB should easily handle this. What is your error?<br>
<br>
Cheers<br>
Rob <o:p></o:p></p>
</div>
<div>
<div>
<p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto'> <o:p></o:p></p>
</div>
</div>
<p class=MsoNormal><br>
On 22/07/2010 12:30 p.m., John Bird wrote: <o:p></o:p></p>
<pre>Dealing with a timing issue involving Firebird, probably the cause is a slow <o:p></o:p></pre><pre>workstation running the processing program.<o:p></o:p></pre><pre><o:p> </o:p></pre><pre>The workstation occasionally sends a burst of transactions, each involving <o:p></o:p></pre><pre>adding new records to the same two tables. I presume Firebird can handle <o:p></o:p></pre><pre>this<o:p></o:p></pre><pre><o:p> </o:p></pre><pre>The server is a FAST quad core Windows 2003 server running Firebird 2.0 - it <o:p></o:p></pre><pre>should handle a burst of transactions at up to 5 per second for up to 20 or <o:p></o:p></pre><pre>30 seconds?<o:p></o:p></pre><pre><o:p> </o:p></pre><pre>John <o:p></o:p></pre><pre><o:p> </o:p></pre><pre><o:p> </o:p></pre><pre>_______________________________________________<o:p></o:p></pre><pre>NZ Borland Developers Group - Delphi mailing list<o:p></o:p></pre><pre>Post: <a
href="mailto:delphi@delphi.org.nz">delphi@delphi.org.nz</a><o:p></o:p></pre><pre>Admin: <a
href="http://delphi.org.nz/mailman/listinfo/delphi">http://delphi.org.nz/mailman/listinfo/delphi</a><o:p></o:p></pre><pre>Unsubscribe: send an email to <a
href="mailto:delphi-request@delphi.org.nz">delphi-request@delphi.org.nz</a> with Subject: unsubscribe<o:p></o:p></pre><pre><o:p> </o:p></pre><pre> <o:p></o:p></pre>
<div class=MsoNormal align=center style='text-align:center'>
<hr size=2 width="100%" align=center>
</div>
<p class=MsoNormal>_______________________________________________<br>
NZ Borland Developers Group - Delphi mailing list<br>
Post: <a href="mailto:delphi@delphi.org.nz">delphi@delphi.org.nz</a><br>
Admin: <a href="http://delphi.org.nz/mailman/listinfo/delphi">http://delphi.org.nz/mailman/listinfo/delphi</a><br>
Unsubscribe: send an email to <a href="mailto:delphi-request@delphi.org.nz">delphi-request@delphi.org.nz</a>
with Subject: unsubscribe<o:p></o:p></p>
<div class=MsoNormal align=center style='text-align:center'><span
style='color:windowtext'>
<hr size=2 width="100%" align=center>
</span></div>
<p class=MsoNormal><span style='color:windowtext'>_______________________________________________<br>
NZ Borland Developers Group - Delphi mailing list<br>
Post: delphi@delphi.org.nz<br>
Admin: http://delphi.org.nz/mailman/listinfo/delphi<br>
Unsubscribe: send an email to delphi-request@delphi.org.nz with Subject:
unsubscribe<o:p></o:p></span></p>
</div>
</body>
</html>