How to configure that automatically displays the TZquery in a TDBGrid a field array the Firebird as blob?
For example, the IBExpert and Flamerobin make it transparent to the user.
Database: EMPLOYER
Query: SELECT * FROM JOB
Erro in "ZQuery1.Open": Cannot access blob record in column 8 with type String
Column 8: LANGUAGE_REQ is a array field
How do the TZQuery display fields array as blob in Firebird?
-
- Platinum Boarder
- Posts: 1956
- Joined: 17.01.2011, 14:17
Hello jepafi
It seem's to be a BUG in Zeos. Because the Columm 8 ist NOT A BLOB field.
The EMPLOYEE.FDB or EMPLOYEE.GDB are included as Test-Data from Firebird/Intebase.
So they should be Checked From the Zeos Lib - Team.
I am gettin the error even if the Field JOB_REQUIREMENT ( That's the BLOB Field ) is noch in the Query.
Structure of the Table: JOB
CREATE TABLE JOB (
JOB_CODE JOBCODE NOT NULL,
JOB_GRADE JOBGRADE NOT NULL,
JOB_COUNTRY COUNTRYNAME NOT NULL,
JOB_TITLE VARCHAR(25) NOT NULL,
MIN_SALARY SALARY NOT NULL,
MAX_SALARY SALARY NOT NULL,
JOB_REQUIREMENT BLOB SUB_TYPE 1 SEGMENT SIZE 400,
LANGUAGE_REQ VARCHAR(15)[5]);
QUERY: ( FOR ALL FIELDS )
SELECT FIRST 1000 JOB_GRADE, MIN_SALARY, MAX_SALARY, JOB_CODE, JOB_COUNTRY, JOB_TITLE, LANGUAGE_REQ, JOB_REQUIREMENT FROM JOB
The Error-Message:
Cannot Acces blob record in column 7 with type String.
QUERY 1: ( Without the BLOB field JOB_REQUIREMENT )
SELECT FIRST 1000 JOB_GRADE, MIN_SALARY, MAX_SALARY, JOB_CODE, JOB_COUNTRY, JOB_TITLE, LANGUAGE_REQ FROM JOB
The Error-Message:
Cannot Acces blob record in column 7 with type String.
This is the SAME EROR with and without the BLOB_FIELD!!!
In the next SQL-Statement i took the Array-Field LANGUAGE_REQ away and put the BLOB JOB_REQUIREMENT in !
SELECT FIRST 1000 JOB_GRADE, MIN_SALARY, MAX_SALARY, JOB_CODE, JOB_COUNTRY, JOB_TITLE, JOB_REQUIREMENT FROM JOB
Now the Error ist gone!
The Problem is not the BLOB, it is the Array Field.
The fired Error-Message is wrong....
Greatings
Fuat
I am working with Lazarus v1.0, Delpi XE3 ...
It seem's to be a BUG in Zeos. Because the Columm 8 ist NOT A BLOB field.
The EMPLOYEE.FDB or EMPLOYEE.GDB are included as Test-Data from Firebird/Intebase.
So they should be Checked From the Zeos Lib - Team.
I am gettin the error even if the Field JOB_REQUIREMENT ( That's the BLOB Field ) is noch in the Query.
Structure of the Table: JOB
CREATE TABLE JOB (
JOB_CODE JOBCODE NOT NULL,
JOB_GRADE JOBGRADE NOT NULL,
JOB_COUNTRY COUNTRYNAME NOT NULL,
JOB_TITLE VARCHAR(25) NOT NULL,
MIN_SALARY SALARY NOT NULL,
MAX_SALARY SALARY NOT NULL,
JOB_REQUIREMENT BLOB SUB_TYPE 1 SEGMENT SIZE 400,
LANGUAGE_REQ VARCHAR(15)[5]);
QUERY: ( FOR ALL FIELDS )
SELECT FIRST 1000 JOB_GRADE, MIN_SALARY, MAX_SALARY, JOB_CODE, JOB_COUNTRY, JOB_TITLE, LANGUAGE_REQ, JOB_REQUIREMENT FROM JOB
The Error-Message:
Cannot Acces blob record in column 7 with type String.
QUERY 1: ( Without the BLOB field JOB_REQUIREMENT )
SELECT FIRST 1000 JOB_GRADE, MIN_SALARY, MAX_SALARY, JOB_CODE, JOB_COUNTRY, JOB_TITLE, LANGUAGE_REQ FROM JOB
The Error-Message:
Cannot Acces blob record in column 7 with type String.
This is the SAME EROR with and without the BLOB_FIELD!!!
In the next SQL-Statement i took the Array-Field LANGUAGE_REQ away and put the BLOB JOB_REQUIREMENT in !
SELECT FIRST 1000 JOB_GRADE, MIN_SALARY, MAX_SALARY, JOB_CODE, JOB_COUNTRY, JOB_TITLE, JOB_REQUIREMENT FROM JOB
Now the Error ist gone!
The Problem is not the BLOB, it is the Array Field.
The fired Error-Message is wrong....
Greatings
Fuat
I am working with Lazarus v1.0, Delpi XE3 ...
- EgonHugeist
- Zeos Project Manager
- Posts: 1936
- Joined: 31.03.2011, 22:38
Fuat,
there is something missing, currently. We could handle a patch with Delphi, if we would create a NestedDataSet virtually. But there is nothing possible with the current FPC. No way...
I could have a look. But isn't a different select possible too? Something untested like this:
"select LANGUAGE_REQ[1] as LANGUAGE_REQ1, LANGUAGE_REQ[2] as LANGUAGE_REQ2 from JOB;" ??
there is something missing, currently. We could handle a patch with Delphi, if we would create a NestedDataSet virtually. But there is nothing possible with the current FPC. No way...
I could have a look. But isn't a different select possible too? Something untested like this:
"select LANGUAGE_REQ[1] as LANGUAGE_REQ1, LANGUAGE_REQ[2] as LANGUAGE_REQ2 from JOB;" ??
Best regards, Michael
You want to help? http://zeoslib.sourceforge.net/viewtopic.php?f=4&t=3671
You found a (possible) bug? Use the new bugtracker dude! http://sourceforge.net/p/zeoslib/tickets/
You want to help? http://zeoslib.sourceforge.net/viewtopic.php?f=4&t=3671
You found a (possible) bug? Use the new bugtracker dude! http://sourceforge.net/p/zeoslib/tickets/