Subject Re: [Firebird-Java] Re: JDBC 1.5.0rc2 'invalid BLOB id'
Author Stanislav Mironov
Roman Rokytskyy wrote:

> > I'm trying to select BLOB data from a view and it fails with "invalid
> > BLOB id' error message. Does anyone know how to fix this error?
> >
> > On JDBC driver 1.0.1 everything is OK.
>
> Do you mean when you use JayBird 1.5 RC2 your application fails, when
> you replace it with JayBird 1.0.1, it works with the same database and
> same application? Can you create a reproducable test case? Is it
> specific for the database or this problem can be reproduced on any
> database?


This can be reproduced on any base.

1. Create database as sysdba, DEFAULT CHARACTER SET WIN1251.

2. CREATE TABLE SCREENSHOT_DATA (
ENT_ID NUMERIC(18),
DB_ID NUMERIC(18),
DOC_ID NUMERIC(18),
LINE_ORDER NUMERIC(18),
SCREEN_PICTURE BLOB
);

3. CREATE VIEW SCREENSHOT_V_DATA (
ENT_ID,
DB_ID,
DOC_ID,
LINE_ORDER,
SCREEN_PICTURE
) AS
SELECT ENT_ID, DB_ID, DOC_ID, LINE_ORDER, SCREEN_PICTURE FROM
SCREENSHOT_DATA;

4. INSERT INTO SCREENSHOT_V_DATA VALUES(...) via PreparedStatement

5. SELECT SCREEN_PICTURE FROM SCREENSHOT_V_DATA_VALUES;
Exception 'invalid BLOB ID'.

I hope this bug will be fixed before final release.

--
Stanislav Mironov