Re: pgAdmin4 (v 4.11) SELECT * returns 'table_oid'

Tony Bazeley <[email protected]> Sun, 11 Aug 2019 10:51:11 +0930
Newsgroups gmane.comp.db.postgresql.pgadmin
Message-ID <[email protected]>
Apologies - I see this is being
actively managed here: https://redmine.postgresql.org/issues/4520#change-17568

On 11/8/19 8:28 am, Tony Bazeley wrote:

I'm no python programmer and have
installed 4.11 under Kubuntu 19.04

My python version is:

~$ python3 -V

Python 3.7.3

I installed psycopg2

~$ sudo pip3 install -U psycopg2

And have a psycopg2 set of files in
what seems to be an appropriate spot

~$ ls -l
/usr/share/pgadmin4/web/pgadmin/utils/driver/psycopg2

total 152

-rw-r--r-- 1 root root 68788 Jul 23 14:45 connection.py

-rw-r--r-- 1 root root 7750 Jul 23 14:45 cursor.py

-rw-r--r-- 1 root root 3549 Jul 23 14:45 encoding.py

-rw-r--r-- 1 root root 2259 Jul 23 14:45 generate_keywords.py

-rw-r--r-- 1 root root 12706 Jul 23 14:45 __init__.py

-rw-r--r-- 1 root root 9375 Jul 23 14:45 keywords.py

drwxr-xr-x 2 root root 4096 Aug 11 00:02 __pycache__

-rw-r--r-- 1 root root 20569 Jul 23 14:45 server_manager.py

-rw-r--r-- 1 root root 8416 Jul 23 14:45 typecast.py

But the problem persists

Using the
tablename>view/edit/data facility works, but using the same
sql in the Query Tool returns 'table_oid'

Any thoughts on what to do next
would be greatly appreciated

Tony

On 28/7/19 6:27 pm, Dave Page wrote:

On 27 Jul 2019, at 21:14, richard coleman <[email protected] >
wrote:

'ello all,

When running the following query:

SELECT * FROM live.tbl_documents limit 10000;

in pgAdmin4 it returns no output and switches
to the Messages tab with the following message:

'table_oid'

Upgrade psycopg2 to 2.8.3. pgAdmin has required 2.8.x for
some time.

The same query against the same table in the same
database run at the psql prompt returns the records as
expected.

postgreSQL 10.3

using pgAdmin4

Version

4.11

Copyright

Copyright (C) 2013 - 2019, The pgAdmin Development Team

Python Version

3.6.8 (default, Jan 14 2019, 11:02:34) [GCC 8.0.1
20180414 (experimental) [trunk revision 259383]]

Flask Version

0.12.2

Application Mode

Desktop

Current User

[email protected]

Running on Chromium

Version 75.0.3770.90 (Official Build) Built on Ubuntu
, running on Ubuntu 18.04 (64-bit)

Kubuntu 18.04.

Table:

CREATE TABLE live.tbl_documents

(

id character varying(50) COLLATE
pg_catalog."default" NOT NULL,

company_no character varying(32) COLLATE
pg_catalog."default",

tariff_id integer,

scac character(4) COLLATE pg_catalog."default",

type character varying(50) COLLATE
pg_catalog."default" NOT NULL,

name character varying(200) COLLATE
pg_catalog."default" NOT NULL,

filelocation character varying(200) COLLATE
pg_catalog."default" NOT NULL,

description character varying(200) COLLATE
pg_catalog."default" NOT NULL,

archive boolean NOT NULL DEFAULT false,

par_id character varying(50) COLLATE
pg_catalog."default",

category character varying(250) COLLATE
pg_catalog."default",

visible_in_vision boolean NOT NULL DEFAULT false,

tariffrequest_id character varying(50) COLLATE
pg_catalog."default",

entered_on timestamp without time zone NOT NULL
DEFAULT now(),

invoice_id character varying(40) COLLATE
pg_catalog."default",

lastwritetime timestamp without time zone,

shipment_id character varying(40) COLLATE
pg_catalog."default",

CONSTRAINT tbl_documents_pkey PRIMARY KEY (id),

CONSTRAINT tbl_documents_par_id_fkey FOREIGN KEY
(par_id)

REFERENCES live.tbl_pars (par_id) MATCH SIMPLE

ON UPDATE NO ACTION

ON DELETE NO ACTION

)

WITH (

OIDS = FALSE

)

TABLESPACE pg_default;