Received: from maia.hub.org (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id 308C663373B for ; Thu, 18 Mar 2010 19:59:52 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.208.211]) (amavisd-maia, port 10024) with ESMTP id 35077-07 for ; Thu, 18 Mar 2010 22:59:35 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by mail.postgresql.org (Postfix) with ESMTP id 6E8616335A9 for ; Thu, 18 Mar 2010 19:59:41 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id o2IMxcpJ019216; Thu, 18 Mar 2010 18:59:38 -0400 (EDT) To: Dmitriy Igrishin cc: postgres list Subject: Re: Emacs sql-postgres (please, sorry for question not about PostgreSQL). In-reply-to: References: Comments: In-reply-to Dmitriy Igrishin message dated "Fri, 19 Mar 2010 00:43:57 +0300" Date: Thu, 18 Mar 2010 18:59:38 -0400 Message-ID: <19215.1268953178@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.46 tagged_above=-10 required=5 tests=AWL=0.139, BAYES_00=-2.599 X-Spam-Level: X-Archive-Number: 201003/154 X-Sequence-Number: 33861 Dmitriy Igrishin writes: > I am using Emacs recently. I love sql-mode, to use with PostgreSQL, > but I have problems with it. > When my SQL file (or buffer) are small (50-100 lines) I can send > it to SQLi buffer without any problems. But when I working with > large SQL file (e.g. complex database model, thousands of lines) > and send it to SQLi buffer it does not work properly. Something > going on and in SQLi buffer (psql) I see incomplete SQL > statement, for example: > super=# super'# super'# super'# super'# > It seems to single quote was not closed. But SQL is absolutely > correct and loads fine when I load it from file directly from psql. > I think, the problem with Emacs buffers... Please, help! Might or might not be related, but I've seen psql lock up when I try to paste more than a thousand or two characters into it via X11 copy-and-paste. You might find that disabling libreadline (option -n to psql) helps. regards, tom lane