#1 2014-09-15 12:53:12

chapa
Member
Registered: 2012-04-30
Posts: 117

ZEOS + Postgres Remote Server

Hi ab,

Just start playing with ZEOS + Postgresql.
What I find out is when try to set remote server and/or port in TSQLDBZEOSConnectionProperties.URI() class function where if aLibraryLocation='' then we exit and miss the chance to set result+'//'+aServerName

Offline

#2 2014-09-15 13:24:58

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,659
Website

Re: ZEOS + Postgres Remote Server

Indeed.
(on our side, we always specified the library, for safety about potential issues in the Windows path)

We have just fixed TSQLDBZEOSConnectionProperties.URI() when aLibraryLocation=''.
See http://synopse.info/fossil/info/60c0380334

Thanks for the feedback.

Online

#3 2014-09-15 13:32:25

chapa
Member
Registered: 2012-04-30
Posts: 117

Re: ZEOS + Postgres Remote Server

Also,

CreateMissingTables() seems to explicit create unique index by id:
CREATE UNIQUE INDEX ndxsamplerecordid ON public.samplerecord USING btree (id);

but Postgresql creates index on the fly when PrimaryKey Constraint specified in Create Table:
CREATE TABLE public.samplerecord (
  id INTEGER NOT NULL,
  ...
  CONSTRAINT samplerecord_pkey PRIMARY KEY(id)
)

All tables end up with duplicate index for primary id key.
Extra index, extra disk size, extra row update time.

Offline

#4 2014-09-15 15:56:00

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,659
Website

Re: ZEOS + Postgres Remote Server

Indeed.

I tried to check the databases which are known to create indexes on primary key.
It is not clear to me if DB2 does create it or not...
And in all cases, we create a descending index for FireBird, so that SELECT maxid from max(ID) performance is maximimized.

See http://synopse.info/fossil/info/c0a02b14ae

Online

Board footer

Powered by FluxBB