X-Original-To: pgsql-performance@postgresql.org Received: from spampd.localdomain (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 2E98A47632B for ; Tue, 29 Apr 2003 09:53:54 -0400 (EDT) Received: from mail.reviewer.co.uk (frodo.reviewer.co.uk [213.232.121.13]) by postgresql.org (Postfix) with SMTP id 0F598475F34 for ; Tue, 29 Apr 2003 09:53:18 -0400 (EDT) Received: (qmail 5861 invoked from network); 29 Apr 2003 13:53:18 -0000 Received: from unknown (HELO LAIKA) (62.49.176.243) by mail.reviewer.co.uk with SMTP; 29 Apr 2003 13:53:18 -0000 From: "Robert John Shepherd" To: Subject: Best ODBC cursor and lock types for fastest reading? Date: Tue, 29 Apr 2003 14:53:18 +0100 Message-ID: <001701c30e56$b0964400$f3b0313e@LAIKA> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook, Build 10.0.2627 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 Importance: Normal X-Spam-Status: No, hits=-1.8 required=5.0 tests=BAYES_20,NO_DNS_FOR_FROM version=2.50 X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.50 (1.173-2003-02-20-exp) X-Archive-Number: 200304/242 X-Sequence-Number: 1748 I access Postgresql through the ODBC driver, and always only read small recordsets (never updating them) with forward cursors. The following options are defined in ADO with which I can create a recordset with: Cursor types: adOpenForwardOnly (what I currently use) adOpenKeyset adOpenDynamic adOpenStatic Lock types: adLockReadOnly adLockPessimistic adLockOptimistic (what I currently use) adLockBatchOptimistic Do any of these offer a performance gain over others? I used to use adLockReadOnly with MS-SQL which really sped things up but this doesn't seem to work at all under Postgresql and I've been using adLockOptimistic instead. Yours Unwhettedly, Robert John Shepherd. Editor DVD REVIEWER The UK's BIGGEST Online DVD Magazine http://www.dvd.reviewer.co.uk For a copy of my Public PGP key, email: pgp@robertsworld.org.uk