[Gambas-devel] makefile !!!
oreip at ...1...
Tue Oct 11 12:09:09 CEST 2005
On 10/10/2005 23:41, Daniel wrote:
> ok, this is for the 1.9.20
I've found a small problem in the firebird component regarding retrieving field
names in a table.
If I tried
DIM c AS NEW Connection
DIM hTables AS Object
DIM hFields AS Object
.Type = "firebird"
.Host = "localhost"
.Name = "/my/path/to/database.gdb"
.Login = "blabla"
.Password = "blabla"
FOR EACH hTables IN c.Tables
IF NOT (Left(hTables.Name, 4) = "RDB$") THEN
PRINT "Table: " & hTables.Name
FOR EACH hFields IN hTables.Fields
the program died unexpectedly raising the famous signal #6.
After a little investigation, I found out that the problem was on line 1690 of
In fact, the problem occurred with a field like this
CREATE TABLE test (
DATA date default 'now',
so I changed the query in line 1690 from "select *" to "select rdb$field_name"
and the problem disappeared.
Since the actual data returned by the query doesn't seem to matter (it's just
the number of returned rows that counts and doing a "select *" seems a bit
overkill), changing the query this way shouldn't do any harm.
I haven't investigated too deep to see where the actual fault comes up but I
made a guess.
From isql, doing a select like
select * from rdb$relation_fields where rdb$relation_name='TEST';
gives (on a date field without default value) a result like
and no crash whereas on a date field with default value I get
BLOB display set to subtype 1. This BLOB: subtype = 2
and a crash.
That BLOB line and the following empty one look suspicious to me and that is
most likely the cause of the crash.
My guess seems to be confirmed by the fact that selecting only RDB$FIELD_NAME
eliminates any problems.
I am using Firebird V126.96.36.19981, don't know if things have changed in other
More information about the Devel