FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Low-Level Functions for DBF - QA Interface
Posts: 6984
Joined: Fri Oct 07, 2005 07:07 PM
Low-Level Functions for DBF - QA Interface
Posted: Wed Jul 31, 2024 06:44 PM
Hello friends,

Working on my own interface for DBF with the help of ChatGPT has been really fun.
The interface is being developed specifically for access from a web server, so many features
that are standard on the desktop are not necessary here.

The main functions are already working very well. I am now considering whether to use terminology
that aligns more with SQL or dBase.

SQL terminology seems more modern and likely more familiar to users, so I will likely choose that path.








Posts: 7318
Joined: Thu Oct 18, 2012 07:17 PM
Re: Low-Level Functions for DBF - QA Interface
Posted: Wed Jul 31, 2024 09:00 PM

don't trust ChatGPT /gemini .... I've tried many artificial intelligences but none of them know the fwh / harbour language thoroughly, they often change commands and functions, I've wasted a lot of time with these artificial intelligences, I still haven't found any that work well

Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)

I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: Low-Level Functions for DBF - QA Interface
Posted: Thu Aug 01, 2024 12:03 AM
ROLLBACK:
Code (fw): Select all Collapse
   USE CUSTOMER NEW VIA "DBFCDX"
   GOTO 5
   USE STATES   NEW VIA "DBFCDX"
   GOTO 10
   ? CUSTOMER->CITY, STATES->NAME // -> "Tarzana,Minnisota"
   //
   REPLACE CUSTOMER->CITY WITH UPPER(CUSTOMER->CITY)
   REPLACE STATES->NAME WITH UPPER(STATES->NAME)
   ? CUSTOMER->CITY, STATES->NAME // -> "TARZANA,MINNISOTA"
   //
   DBROLLBACKALL()
   ? CUSTOMER->CITY, STATES->NAME // -> "Tarzana,Minnisota"

   CLOSE DATA
HI knows what AI does not know.
Regards



G. N. Rao.

Hyderabad, India
Posts: 6984
Joined: Fri Oct 07, 2005 07:07 PM
Re: Low-Level Functions for DBF - QA Interface
Posted: Thu Aug 01, 2024 07:48 AM
Dear Mr. Rao,
I think you learn a lot when you deal directly with the basics.

DBROLLBACKALL() is simply an analogy created by ChatGPT. This command does not actually exist.
You need to ask further questions.
For example. "A suggestion?"
Instead of backing up each record individually, you can employ a temporary backup database or use a shadow file mechanism.

An interesting solution seems to be a batch file for backup and restore.
I once tried it with three large files that are included in a transaction in my program.
It is surprisingly fast—30 to 70 ms for the backup!

In any case, I’m sticking with it.

Best regards,
Otto


Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: Low-Level Functions for DBF - QA Interface
Posted: Fri Aug 02, 2024 03:51 PM
DBROLLBACKALL() is simply an analogy created by ChatGPT.
This has nothing to do with ChatGPT. I see from your above table, that ChatGPT said there is no equivalent to ROLLBACK in DBF

This is an FWH function.
DBROLLBACK() and DBROLLBACKALL()
Regards



G. N. Rao.

Hyderabad, India
Posts: 8523
Joined: Tue Dec 20, 2005 07:36 PM
Re: Low-Level Functions for DBF - QA Interface
Posted: Fri Aug 02, 2024 04:38 PM
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
Posts: 6984
Joined: Fri Oct 07, 2005 07:07 PM
Re: Low-Level Functions for DBF - QA Interface
Posted: Fri Aug 02, 2024 05:17 PM

Dear Mr. Rao,

I am sorry. I misunderstood your response.

I will take a look at and study these two functions right away.

Thank you very much.

I am facing so much opposition here that I am already becoming paranoid.

Best regards from Sillian.

Best regards,

Otto

Posts: 866
Joined: Tue Oct 16, 2007 08:57 AM
Re: Low-Level Functions for DBF - QA Interface
Posted: Sat Aug 03, 2024 05:40 PM
Otto wrote:Dear Mr. Rao,

I am sorry. I misunderstood your response.
I will take a look at and study these two functions right away.
Thank you very much.

I am facing so much opposition here that I am already becoming paranoid.

Best regards from Sillian.
Best regards,
Otto
Dear Otto,

Take a easy.
Best Regards,



Richard



Harbour 3.2.0dev (r2503251254) => Borland C++ v7.7 32bit

MySQL v8.0

Harbour 3.2.0dev (r2503251254) => Borland C++ v7.7 64bit
Posts: 6984
Joined: Fri Oct 07, 2005 07:07 PM
Re: Low-Level Functions for DBF - QA Interface
Posted: Mon Aug 05, 2024 07:37 AM

Dear Richard,

Thank you.

But now is not the time.

Everything is changing, and if you want to stay in business—I mean, if you plan for your software to continue being used by users—it requires great effort.

New web applications appear daily, trying to take market share.

Without a proper web application, I think it will be hopeless to survive.

That's why I'm stressed. It's a lot of work to transform an application that has been developed over 30 years.

Help would certainly be advantageous here.

But now I see that in our group, many different priorities are being set.

Yet, there is practically little interest in the web.

Still, I have to figure out how best—and most economically—to transform the application.

But I've already come a long way with it. Really far.

Best regards,

Otto

Continue the discussion