var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: blob image issue
DB2 version: 7.2.7(enterprise) and 8.1.3(workgroup)
i need to export a table with a blob image to another database. I have used the IXF format and realised that after the import, the image has some blacklines on top of it.
The problem persists though I have tried both from 7.2.7 to 7.2.7 and from 8.1.3 to 8.1.3.
below is the table structure, the image is inserted into the database thru streaming (JAVA).
CREATE TABLE myblobtable
ID INTEGER NOT NULL,
SSTEXT VARCHAR(500) NOT NULL,
SSIMAGE BLOB(100K) LOGGED NOT COMPACT ,
NUMIMAGE SMALLINT NOT NULL DEFAULT 0,
NUMCONTENT SMALLINT NOT NULL DEFAULT 0,
NUMPDF SMALLINT NOT NULL DEFAULT 0,
constraint myblobtable_PK primary key (ID)
At the moment, the only workaround is to use the Java application to stream the data in to the new database.
Btw, I tried to import thru del but encounter error SQLSTATE = 42601
db2> export to myfile.del of del lobs to mylobs/lobfile lobs1, lobs2 modified by lobsfile select * from myblobtable
Any assistance greatly appreciated.
I'm not sure if this is your problem, but you have a typo on the command:
modified by lobsfile sould be modified by lobsinfile
Without this modifier, DB2 will put your lobs in the export file (myfile.del), and truncate them to 32K.
The typo error is my error when i post the issue.
Anyway,I realised that I cannot use del since the SSText is a multi line stylesheet codes so when importing it seems to treat each line as each row even when i set the coldel"" chardel,
Anyway, i manage to get it right by using the following:
export to c:\myfile.IXF of ixf lobs to c:\mylobpath lobfile lobs1, lobs2 modified by lobsinfile select * from myblobtable
import from c:\myfile.IXF of ixf lobs from c:\mylobpath modified by lobsinfile insert into myblobtable
thanks rodney for your prompt response. Btw, any tips on how to import del format of multiline data.
extracted from datafile:
99,"<?xml version='1.0' encoding='ISO-8859-1'?>
<xsl:stylesheet xmlns:xsl='http://www.w3.org/1999/XSL/Transform' version='1.0'>
<xsl utput method='html'/></tr>...
</xsl:stylesheet>","lobs1.001.0.35190/",1,1,2,1,"bmp","Image On Top"