Hi everybody,
I was trying to connect to my PostgreSQL db using ODBC, OOoBase could
establish a connection and show the tables in the PUBLIC squema. But
when I tried to open the table or to create a form, it throws the
following error "ERROR: column OID does not exist; Error while executing
the query".
So I created the following two tables using psql (PostgresSQL
interactive terminal), one with OIDs, the other without it:
CREATE TABLE cuidades(
id_ciudad serial NOT NULL,
cuidad character varying(80) NOT NULL,
CONSTRAINT cuidades_pkey PRIMARY KEY (id_ciudad)
)
WITHOUT OIDS;
CREATE TABLE paises(
id_pais serial NOT NULL,
pais character varying(80) NOT NULL,
codigo character(2),
poblacion integer
CONSTRAINT paises_pkey PRIMARY KEY (id_pais)
)
WITH OIDS;
And I connected with ODBC and the SDBC driver, having the following
strange behavior:
* with ODBC: the table without OIDs trows the error (opening the table
and trying to create a form, report, query). The table WITH oids works O.K.
*with SDBC driver: both tables can be opened, BUT the table WITH oids is
READ-ONLY. I created a table with OOoBase and noticed that the default
CREATE TABLE statement that sends OOoBase to the server is WITHOUT OIDS.
Another strange behavior:
*ODBC shows only the tables in the PUBLIC squema
*SDBC shows the tables of the pg_catalog, the information_squema and the
public squemas (the first read-only, and I think it's for security or
because PostgreSQL uses OIDs with them).
If someone knows if it's a bug or a driver's problem, please let me know
(for, as I usually create my tables WITHOUT oids, if it's a drivers
problem , I will have to choose between one of them)
Thanks. Ariel.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]