PostGreSql and indexes

Hier dreht es sich um den PostGre Server

Moderator: Moderatoren

Antworten
Benutzeravatar
rdonnay
Rookie
Rookie
Beiträge: 3
Registriert: Fr, 14. Jan 2022 18:30
Danksagung erhalten: 6 Mal

PostGreSql and indexes

Beitrag von rdonnay »

After Tom Liehr's review of the most current Xbase++ PGDBE, I decided to make another run at this.

I'm using my SqlQuery tool to connect to PostGreSQL 8.3. I have used pgAdmin3.

I upsized a few ADS databases and am doing browses in both ISAM mode and SQL using PGDBE using SqlQuery.
Performance looks really good under SQL and ISAM.

What experiences do any of you have with indexes under ISAM?
I cannot make OrdsetFocus(<tag name>) work as it did with ADS.
I can see the indexes in the schema under Pgadmin3, but dbInfo() doesn't return any index info.
Is it possible to use dbSeek() and dbSetScope()?

Also. dbinfo() returns incorrect Table name info.

We don't use filters, but indexes are important for our many One-to-Many screens, and other parent/child relations.

Am I wasting my time trying to use PGDBE in ISAM mode?
ramses
Der Entwickler von "Deep Thought"
Der Entwickler von "Deep Thought"
Beiträge: 2513
Registriert: Mi, 28. Jul 2010 17:16
Hat sich bedankt: 12 Mal
Danksagung erhalten: 77 Mal

Re: PostGreSql and indexes

Beitrag von ramses »

rdonnay hat geschrieben: Di, 18. Jan 2022 22:21 Am I wasting my time trying to use PGDBE in ISAM mode?
In my opinion, yes.
When data is used by several different programs, the ISAM mode with its Alaska specific special fields and functions brings only trouble, worries and problems and lost of time.
Valar Morghulis

Gruss Carlo
Benutzeravatar
Tom
Der Entwickler von "Deep Thought"
Der Entwickler von "Deep Thought"
Beiträge: 9345
Registriert: Do, 22. Sep 2005 23:11
Wohnort: Berlin
Hat sich bedankt: 100 Mal
Danksagung erhalten: 359 Mal
Kontaktdaten:

Re: PostGreSql and indexes

Beitrag von Tom »

But if you and your software are the only ones writing data, it is an excellent option. 8)
Herzlich,
Tom
Benutzeravatar
AUGE_OHR
Marvin
Marvin
Beiträge: 12903
Registriert: Do, 16. Mär 2006 7:55
Wohnort: Hamburg
Hat sich bedankt: 19 Mal
Danksagung erhalten: 44 Mal

Re: PostGreSql and indexes

Beitrag von AUGE_OHR »

hi,

as Carlo say : PgDBE does limit you and your Customer to Alaska Concept.

for Xbase++ v2.x ask Werner Bayern for Pass-Through Mode
for Xbase++ v1.9 you can use this Source from Phil Ide which still work with PostgreSQL v12 Server
xbpgsql.zip
(38.57 KiB) 360-mal heruntergeladen
gruss by OHR
Jimmy
Benutzeravatar
Tom
Der Entwickler von "Deep Thought"
Der Entwickler von "Deep Thought"
Beiträge: 9345
Registriert: Do, 22. Sep 2005 23:11
Wohnort: Berlin
Hat sich bedankt: 100 Mal
Danksagung erhalten: 359 Mal
Kontaktdaten:

Re: PostGreSql and indexes

Beitrag von Tom »

as Carlo say : PgDBE does limit you and your Customer to Alaska Concept.
PgDBE works. It moves an application made with Xbase++ to SQL with very low effort. It increases the value of your app by a big factor.

If you don't want to go that way, go your way. But please stop complaining or dealing with libraries made by single people (!) decades ago. The question here was: Does the PGDBE do what it is supposed to do. And the answer is: Yes, even more than that.

If you want to get rid of Alaska and create an application which is safe for the future, what the fuck are you doing in this forum?
Herzlich,
Tom
Benutzeravatar
AUGE_OHR
Marvin
Marvin
Beiträge: 12903
Registriert: Do, 16. Mär 2006 7:55
Wohnort: Hamburg
Hat sich bedankt: 19 Mal
Danksagung erhalten: 44 Mal

Re: PostGreSql and indexes

Beitrag von AUGE_OHR »

hi Tom,

there are at least 3 People who work "native" or with ""Pass-Through" Mode in this Forum

Roger have ask for PgDBE and ISAM Concept and at least 3 People does not like PgDBE Concept.

we have made own Concept and my and Carlo Concept based on Ot4XB which Original was from Phil Ide
we have learn a lot of PostgreSQL in last 10 Years ... while other begin now

---

Phil Ide Code, from 2003, show that Idea was not new when Alaska present PgDBE 2012
this great Work was given to Community to show how easy it can be integrade into Xbase++

based on that Code my PostgreSQL Apps run since 2013 well and stabil.
2 Years ago, when start with 64 Bit under harbour, my 1st. Project was to create a 64 Bit "Wrapper"

for that Project i went back from Ot4Xb Version to Phil Ide Code with DLL Function.
so that Code is "to learn" how to use PostgreSQL Server with Xbase++ and still valid :D

---
gruss by OHR
Jimmy
Benutzeravatar
Tom
Der Entwickler von "Deep Thought"
Der Entwickler von "Deep Thought"
Beiträge: 9345
Registriert: Do, 22. Sep 2005 23:11
Wohnort: Berlin
Hat sich bedankt: 100 Mal
Danksagung erhalten: 359 Mal
Kontaktdaten:

Re: PostGreSql and indexes

Beitrag von Tom »

Jimmy,

this is not a competition. Nobody asked: Hey, what's the best, what's the coolest way to SQL? Roger knows that himself; he works with SQL for years and decades. He knows all options.

He asked: Does the PGDBE-concept work? And the answer to that is: Yes. Almost perfect. If you want to work with this option, go ahead.

Whenever someones asks for details, you start complaining and point to completely different concepts. This is amusing somehow, but it eats time and resources.
Herzlich,
Tom
ramses
Der Entwickler von "Deep Thought"
Der Entwickler von "Deep Thought"
Beiträge: 2513
Registriert: Mi, 28. Jul 2010 17:16
Hat sich bedankt: 12 Mal
Danksagung erhalten: 77 Mal

Re: PostGreSql and indexes

Beitrag von ramses »

Tom hat geschrieben: Mi, 19. Jan 2022 20:06 He asked: Does the PGDBE-concept work?
Hello Tom

not quite right, He asked "Am I wasting my time trying to use PGDBE in ISAM mode?"
Valar Morghulis

Gruss Carlo
Benutzeravatar
Tom
Der Entwickler von "Deep Thought"
Der Entwickler von "Deep Thought"
Beiträge: 9345
Registriert: Do, 22. Sep 2005 23:11
Wohnort: Berlin
Hat sich bedankt: 100 Mal
Danksagung erhalten: 359 Mal
Kontaktdaten:

Re: PostGreSql and indexes

Beitrag von Tom »

Hi, Carlo.

This is the same in different words. 8)
Herzlich,
Tom
Benutzeravatar
AUGE_OHR
Marvin
Marvin
Beiträge: 12903
Registriert: Do, 16. Mär 2006 7:55
Wohnort: Hamburg
Hat sich bedankt: 19 Mal
Danksagung erhalten: 44 Mal

Re: PostGreSql and indexes

Beitrag von AUGE_OHR »

hi,

why you want to use SQL :?:
most xBase User will say : to break 2 GB DBF Limit.

but are you sure that it work with 32 Bit PgDBE ISAM App :?:

you have to "upsize" DBF > 2 GB to "testdrive" PgDBE
it will waste Time when PgDBE work less than FoxDBE
gruss by OHR
Jimmy
Benutzeravatar
Tom
Der Entwickler von "Deep Thought"
Der Entwickler von "Deep Thought"
Beiträge: 9345
Registriert: Do, 22. Sep 2005 23:11
Wohnort: Berlin
Hat sich bedankt: 100 Mal
Danksagung erhalten: 359 Mal
Kontaktdaten:

Re: PostGreSql and indexes

Beitrag von Tom »

why you want to use SQL :?:
most xBase User will say : to break 2 GB DBF Limit.
Bullshit.

Why SQL?

To ensure your data is much safer than it is when using a file based database system. To establish an access structure. To improve speed. To have more control about the data. To ensure data integrity. To have the chance to improve the code quality, get more compact code. To move service structures to a server. To open up the database for direct access from other systems (which works perfect even with PG/ISAM). To use modern backup structures. To protect data. To compete on the market. To increase the value of the software.

Your view is just your small my-own-world-view. Go ahead, share your experiences, but stop complaining about something you're just not interested in. Thanks in advance.
Herzlich,
Tom
Benutzeravatar
dtmackenzie
Rekursionen-Architekt
Rekursionen-Architekt
Beiträge: 265
Registriert: Do, 22. Nov 2007 9:02
Wohnort: Leipzig
Hat sich bedankt: 66 Mal
Danksagung erhalten: 22 Mal
Kontaktdaten:

Re: PostGreSql and indexes

Beitrag von dtmackenzie »

Roger,

to try to answer your original question...

Apart from the upsized indexes, I have used OrdCreate() for new ones without problems. After OrdListAdd(), OrdSetFocus() works fine.

I use pgAdmin4 rather than pgAdmin3 - it's actively developed and well supported.

If you haven't already done so, I'd recommend taking the time to look through the Alaska online knowledge base regarding PGDBE and scope etc. - there are a few relevant PDRs that you need to watch out for, e.g. 7416...

You're lucky that you don't use filters - many of my problems are due to my kludged filter emulation (needed because my users can enter filter expressions directly!).

That said, the ISAM emulation in PGDBE is a fine thing. Maybe it's not a "magic wand" for large and complex applications - I've had to put in a hell of a lot of work, but in my case I'm talking about a pair of applications with a common database which together form the ERP system of our company - it has been developed over the last 30 years (half of which before I began with it), and no single person understands all of it (me included!). Nevertheless it is running live via PGDBE ISAM since May last year.

So it may not always be easy, and of course it depends on your aims (Tom summarized many of the benefits nicely, which I'm sure you are also well aware of), but on the basis of my experience I would certainly not regard PGDBE ISAM as a waste of time.

Keep on truckin'!
Viele Grüße,
David
Antworten