- Posts: 5
- Thank you received: 0
×
General discussions, feature requests for CodeTyphon Project and discussions that don't fit in any of the other specific CodeTyphon forum categories.
Question sqlDB Debug Error
- Michael
- Topic Author
- Offline
- New Member
-
Less
More
8 months 1 week ago #16354
by Michael
sqlDB Debug Error was created by Michael
Dear all,
I am under Ubuntu 20.04, X86.64 with CT 7.7. When you make a new project, place a PQConnection, a SQLTransaction and try to connect at runtime with the debugger, the app crash. Without the debugger, the app run. Please see the below example. To crash, a breakpoint must be set on the line
PQConnection1.Connected := true;
Without the breakpoint, the app run. If you run to the breakpoint, then press F8, the following dialog shows:
The file "/build/glibc-eX1tMB/glibc-2.31/elf/dl-error-skeleton.c" could not be found.
Do you like to search for it?
In Design Mode, I can set all the properties for the PQConnection (host, user, password, dbName) and connect without error.
How can this be avoided? Do I need to set the property PQConnection.clientLibrary?
unit Unit1;
{$mode objfpc}{$H+}
interface
uses
Classes, SysUtils, PQConnection, SQLDB, Forms, Controls, Graphics, Dialogs;
type
{ TForm1 }
TForm1 = class(TForm)
PQConnection1: TPQConnection;
SQLQuery1: TSQLQuery;
SQLTransaction1: TSQLTransaction;
procedure FormActivate(Sender: TObject);
private
public
end;
var
Form1: TForm1;
implementation
{$R *.frm}
{ TForm1 }
procedure TForm1.FormActivate(Sender: TObject);
begin
if PQConnection1.Connected = false then begin;
PQConnection1.DatabaseName:= 'kaluga';
PQConnection1.HostName:= 'localhost';
//pgCon.port ??
PQConnection1.UserName:='kaluga_admin';
PQConnection1.Password:='kaluga_admin';
PQConnection1.Connected := true;
SQLTransaction1.Active:= true;
showMessage('connected to postgres DB');
end;
end;
end.
Thanks
I am under Ubuntu 20.04, X86.64 with CT 7.7. When you make a new project, place a PQConnection, a SQLTransaction and try to connect at runtime with the debugger, the app crash. Without the debugger, the app run. Please see the below example. To crash, a breakpoint must be set on the line
PQConnection1.Connected := true;
Without the breakpoint, the app run. If you run to the breakpoint, then press F8, the following dialog shows:
The file "/build/glibc-eX1tMB/glibc-2.31/elf/dl-error-skeleton.c" could not be found.
Do you like to search for it?
In Design Mode, I can set all the properties for the PQConnection (host, user, password, dbName) and connect without error.
How can this be avoided? Do I need to set the property PQConnection.clientLibrary?
unit Unit1;
{$mode objfpc}{$H+}
interface
uses
Classes, SysUtils, PQConnection, SQLDB, Forms, Controls, Graphics, Dialogs;
type
{ TForm1 }
TForm1 = class(TForm)
PQConnection1: TPQConnection;
SQLQuery1: TSQLQuery;
SQLTransaction1: TSQLTransaction;
procedure FormActivate(Sender: TObject);
private
public
end;
var
Form1: TForm1;
implementation
{$R *.frm}
{ TForm1 }
procedure TForm1.FormActivate(Sender: TObject);
begin
if PQConnection1.Connected = false then begin;
PQConnection1.DatabaseName:= 'kaluga';
PQConnection1.HostName:= 'localhost';
//pgCon.port ??
PQConnection1.UserName:='kaluga_admin';
PQConnection1.Password:='kaluga_admin';
PQConnection1.Connected := true;
SQLTransaction1.Active:= true;
showMessage('connected to postgres DB');
end;
end;
end.
Thanks
Please Log in or Create an account to join the conversation.
- Matis A.
-
- Away
- Moderator
-
8 months 1 week ago - 8 months 1 week ago #16357
by Matis A.
PilotLogic Core Programmer
Replied by Matis A. on topic sqlDB Debug Error
Your PQ version ?
Did you test an other debugger ?. CT support on Linux 3 debuggers.
Some Ubuntu ver have problems with GDB and glibc-2.3x
Did you test an other debugger ?. CT support on Linux 3 debuggers.
Some Ubuntu ver have problems with GDB and glibc-2.3x
PilotLogic Core Programmer
Last edit: 8 months 1 week ago by Sternas Stefanos.
Please Log in or Create an account to join the conversation.
- Michael
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 5
- Thank you received: 0
8 months 2 days ago #16390
by Michael
Replied by Michael on topic sqlDB Debug Error
My Postgresql version is 11. In the mean time, I got the same debugger problems on other places as well, so it might not be Postgresql problem. Maybe it is an Ubuntu problem with gdb, as you suggest. I will try to use an other debugger
Please Log in or Create an account to join the conversation.