Error in Query Builder: multi-line sql

From: Colin Beckingham <colbec(at)start(dot)ca>
To: pgadmin-support(at)postgresql(dot)org
Subject: Error in Query Builder: multi-line sql
Date: 2012-03-09 10:09:39
Message-ID: 4F59D6E3.4030609@start.ca
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-support

Using latest 1.15 dev, opensuse 12.1 64 bit.

This is a tough one to describe, no backtrace to offer, no segfault or
other command line message.

1. Open pgadmin, select correct db, open query builder, all ok.
2. cut and paste from Kwrite editor Python code as follows:

select distinct on (mname, nname) mname, nname from grammar \
inner join majors using (mid) \
inner join minors using (nid) \
inner join jxgp using (gid) \
where jxgp.pid = 9

3. try to run this, it fails since line continuation is not valid in
this context. No problemo.
4. go through and edit out the \ chars, but leave as multi-line query.
Try to run, runs ok.
5. attempt to edit line 1, e.g. try to remove distinct clause, all ok
until you hit one of the parentheses to activate the paren matching
routine, QB freezes silently and no longer responds. Line 1 may remain
visible, but the remaining lines are replaced by a light blue rectangle
which fills the edit port. (I realize this will be OS dependent, I am
just giving what I experience.)
5a. slide horizontal slider to the right and back and text reappears in
port. Further editing brings back the blue patch.

6. close QB (window closes correctly and pgadmin seems to be unaware of
the error that happened), reopen QB.
7. now paste sql from line 2 above into the port and this time edit out
the \ and newlines and put everything on line 1. Edit and runs now
proceed normally.
8. break the sql into multiple lines, edits now work ok.

I wondered if I am inserting unprinted characters from Kwrite so I tried
with CLI editor Joe. Same effect.

--
---
Colin Beckingham
613-454-5369
http://www.it4gh.com

Responses

Browse pgadmin-support by date

  From Date Subject
Next Message Bartosz Dmytrak 2012-03-09 10:49:03 Rename Trigger script error
Previous Message Steffen Decker 2012-03-09 07:58:55 Re: [**Octum-Spam**] - 4,35 - Re: Bug on multi screens